/* ARMA3.RU: the look of the old DLE "a3ruBlog" template, made responsive. */
:root {
    --page-width: 945px;
    --aside-width: 250px;
    --gap: 15px;
    --ink: #383838;
    --text: #4f4e4e;
    --muted: #8a8a8a;
    --line: #dedddd;
    --line-dark: #c7c6c6;
    --dark: #1d1d1d;
    --accent: #474747;
}

*, *::before, *::after { box-sizing: border-box; }

html { background: #000; }

body {
    margin: 0;
    background: #000 url("../images/background_5-ux-SUGO.jpg") no-repeat 50% 0;
    color: var(--text);
    font: 14px/1.45 'Roboto', Tahoma, Arial, sans-serif;
    -webkit-text-size-adjust: 100%;
}

a { color: var(--ink); }
img, video, iframe { max-width: 100%; }

.page {
    max-width: var(--page-width);
    margin: 0 auto;
    background: #fff;
    box-shadow: 0 0 10px rgba(0, 0, 0, .5);
}

/* --- Header: looping video strip with the logo, menu and social links over it --- */

.site-header {
    position: relative;
    min-height: 130px;
    background: var(--dark) url("../video/menu-poster-sZIDMsq.jpg") center / cover;
    overflow: hidden;
}

.site-header__video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.site-header__inner {
    position: relative;
    display: flex;
    align-items: center;
    gap: 25px;
    min-height: 130px;
    padding: 18px 25px;
}

.site-header__logo img { display: block; width: 159px; height: 88px; }
.site-header__nav { flex: 1; }
.site-header__descr { color: #b3b2b2; font-size: 12px; text-transform: uppercase; margin-bottom: 4px; }

.site-header__menu { display: flex; flex-wrap: wrap; gap: 4px 22px; }
.site-header__menu a {
    color: #fff;
    font: 20px Tahoma, Arial, sans-serif;
    text-transform: uppercase;
    text-decoration: none;
}
.site-header__menu a:hover { text-shadow: #fff 0 0 3px; }

.site-header__social { display: flex; gap: 8px; }
.site-header__social img { display: block; transition: transform .3s; }
.site-header__social a:hover img { transform: translateY(4px); }

.site-header__search input {
    width: 150px;
    padding: 5px 8px;
    border: 1px solid rgba(255, 255, 255, .35);
    background: rgba(0, 0, 0, .35);
    color: #fff;
    font: inherit;
}
.site-header__search input::placeholder { color: #b3b2b2; }
.site-header__search input:focus { outline: none; border-color: #fff; background: rgba(0, 0, 0, .6); }

/* --- Two columns: content and the partner banners --- */

.layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) var(--aside-width);
    gap: var(--gap);
    padding: var(--gap);
}

.content { min-width: 0; }
.aside { text-align: center; color: #474747; }
.aside__title { font-weight: bold; margin: 8px 0 12px; }
.aside a { display: block; margin-bottom: 18px; }
.aside img { display: block; margin: 0 auto; width: 200px; height: auto; }

.flash { padding: 8px 12px; margin-bottom: var(--gap); background: var(--line); border-left: 4px solid var(--accent); }
.flash--danger { border-color: #b3261e; }
.flash--success { border-color: #2e7d32; }

/* --- Feed --- */

.list-head { margin: 0 0 var(--gap); }
.list-head h1 { margin: 0; font-size: 18px; text-transform: uppercase; color: var(--ink); }
.list-head p { margin: 6px 0 0; color: var(--muted); }

.news-block { margin-bottom: 26px; }
.news-block__title {
    margin: 0;
    font-size: 15px;
    font-weight: bold;
    text-transform: uppercase;
    color: var(--ink);
}
.news-block__title a { color: inherit; text-decoration: none; }
.news-block__title a:hover { text-decoration: underline; }

hr, .rule { height: 4px; margin: 6px 0 10px; background: var(--line); border: 0; }

.news-block__cover { display: block; margin-bottom: 8px; }
.news-block__cover img { display: block; width: 100%; height: auto; }
.news-block__lead { margin: 0; font-weight: 300; font-size: 14px; color: #5d5c5c; }

.meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 14px;
    margin-top: 8px;
    color: var(--muted);
    font-size: 12px;
}
.meta a { color: var(--muted); }
.meta a:hover { color: var(--ink); }
.meta__views { padding-left: 23px; background: url("../images/views-4WWemUU.png") no-repeat left center; }
.meta__right { margin-left: auto; display: flex; gap: 14px; }

.pagination { display: flex; flex-wrap: wrap; gap: 4px; margin: 10px 0; }
.pagination a, .pagination span {
    padding: 4px 9px;
    color: var(--ink);
    background: var(--line);
    text-decoration: none;
}
.pagination a:hover, .pagination .is-current { color: #eee; background: var(--ink); }

.empty { color: var(--muted); }

/* --- A post and the HTML of post bodies --- */

.post__title { margin: 0; font-size: 20px; font-weight: bold; text-transform: uppercase; color: var(--ink); }
.post__tags { margin-top: 18px; display: flex; flex-wrap: wrap; gap: 6px; }
.post__tags a { padding: 2px 8px; background: var(--line); color: var(--ink); text-decoration: none; font-size: 12px; }
.post__tags a:hover { background: var(--ink); color: #eee; }

.prose { font-weight: 300; font-size: 15px; line-height: 1.5; color: #4a4949; overflow-wrap: anywhere; }
.prose b, .prose strong { font-weight: 700; }
.prose a { color: #5f5f5f; }
.prose a:hover { text-decoration: none; }
.prose h2, .prose h3, .prose h4 { color: var(--ink); line-height: 1.25; margin: 1.3em 0 .5em; }
.prose h2 { font-size: 19px; }
.prose h3 { font-size: 16px; text-transform: uppercase; }
.prose h4 { font-size: 15px; }
.prose img { height: auto; }
.prose figure { margin: 1em 0; }
.prose figure img { display: block; margin: 0 auto; }
.prose figcaption { margin-top: 4px; font-size: 13px; color: var(--muted); text-align: center; }
.prose ul { padding-left: 1.4em; }
.prose li { list-style-type: square; }
.prose ol li { list-style-type: decimal; }
.prose blockquote {
    margin: 1em 0;
    padding: 8px 12px;
    background: var(--line);
    border: 1px solid var(--line-dark);
    border-radius: 5px;
}
.prose details { margin: 1em 0; border: 1px solid var(--line-dark); }
.prose summary { padding: 6px 10px; background: #f3f3f3; font-weight: 700; cursor: pointer; }
.prose details > :not(summary) { margin: 10px; }
.prose table { width: 100%; border-collapse: collapse; margin: 1em 0; display: block; overflow-x: auto; }
.prose td, .prose th { padding: 4px 8px; border: 1px solid var(--line-dark); vertical-align: top; }
.prose pre { overflow-x: auto; padding: 8px; background: #f6f6f6; border: 1px solid var(--line); }
.prose abbr[title] { text-decoration: underline dotted; cursor: help; }
.prose audio { width: 100%; }

/* YouTube: a preview that becomes the player on click (see assets/js/video.js). */
.video { margin: 1em 0; }
.video__frame {
    position: relative;
    display: block;
    aspect-ratio: 16 / 9;
    background: #000;
    overflow: hidden;
}
.video__frame img, .video__frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video__frame img { object-fit: cover; }
.video__play {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 68px;
    height: 48px;
    margin: -24px 0 0 -34px;
    opacity: .85;
}
.video__frame:hover .video__play { opacity: 1; }
.video figcaption { margin-top: 4px; font-size: 13px; color: var(--muted); }

/* Full-size picture over the page (assets/js/lightbox.js). */
.prose a[data-lightbox] { cursor: zoom-in; }
.lightbox {
    width: 100vw;
    height: 100vh;
    max-width: none;
    max-height: none;
    margin: 0;
    padding: 0;
    border: 0;
    background: rgba(0, 0, 0, .9);
}
.lightbox::backdrop { background: rgba(0, 0, 0, .6); }
.lightbox img { position: absolute; inset: 0; margin: auto; max-width: 96vw; max-height: 92vh; }
.lightbox button {
    position: absolute;
    border: 0;
    background: rgba(0, 0, 0, .4);
    color: #fff;
    font-size: 40px;
    line-height: 1;
    padding: 10px 16px;
    cursor: pointer;
}
.lightbox button:hover { background: rgba(0, 0, 0, .8); }
.lightbox__prev { left: 8px; top: 50%; transform: translateY(-50%); }
.lightbox__next { right: 8px; top: 50%; transform: translateY(-50%); }
.lightbox__close { right: 8px; top: 8px; }
.lightbox--single .lightbox__prev, .lightbox--single .lightbox__next { display: none; }
.lightbox__count { position: absolute; left: 12px; top: 14px; color: #ccc; font-size: 13px; }

/* --- Search --- */

.search-form { display: flex; gap: 8px; margin-bottom: 20px; }
.search-form input { flex: 1; min-width: 0; padding: 7px 8px; font: inherit; border: 1px solid var(--line-dark); }
.search-hit { margin-bottom: 22px; }
.search-hit__snippet { margin: 6px 0 0; font-weight: 300; color: #5d5c5c; }
.search-hit mark { background: #fff2a8; color: inherit; font-weight: 400; }

/* --- Forms (sign-in pages) --- */

.form-page { max-width: 420px; }
.form { display: grid; gap: 12px; }
.form label { display: grid; gap: 4px; }
.form input { padding: 7px 8px; font: inherit; border: 1px solid var(--line-dark); }
.btn {
    display: inline-block;
    padding: 7px 16px;
    border: 0;
    background: var(--ink);
    color: #fff;
    font: inherit;
    text-decoration: none;
    cursor: pointer;
}
.btn:hover { background: #000; }

.error-page { text-align: center; padding: 40px 0; }
.error-page__code { font-size: 64px; font-weight: 700; color: var(--line-dark); }

/* --- Footer --- */

.site-footer {
    max-width: var(--page-width);
    margin: 0 auto;
    padding: 8px var(--gap) 30px;
    color: #6f6f6f;
    font-size: 11px;
}
.site-footer a { color: #8f8f8f; }

/* --- Narrow screens: one column, compact header --- */

@media (max-width: 760px) {
    .layout { grid-template-columns: minmax(0, 1fr); }
    .aside { border-top: 4px solid var(--line); padding-top: var(--gap); }
    .site-header__video { display: none; }
    .site-header__inner { flex-wrap: wrap; gap: 10px 18px; padding: 12px var(--gap); }
    .site-header__logo img { width: 106px; height: 59px; }
    .site-header__descr { display: none; }
    .site-header__nav { order: 3; flex-basis: 100%; }
    .site-header__menu a { font-size: 16px; }
    .site-header__social { margin-left: auto; }
    .site-header__search { order: 4; flex-basis: 100%; }
    .site-header__search input { width: 100%; }
    .post__title { font-size: 17px; }
}

@media (prefers-reduced-motion: reduce) {
    .site-header__video { display: none; }
}
