/* ================================================================
   LEGACY STYLE — старый веб в стиле 2000-х
   ================================================================ */

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Times New Roman', Times, serif;
    font-size: 15px;
    line-height: 1.6;
    color: #000000;
    background-color: #c0d8c0;
    background-image:
        repeating-linear-gradient(
            45deg,
            #c0d8c0,
            #c0d8c0 4px,
            #b8d0b8 4px,
            #b8d0b8 8px
        );
    padding: 10px 0 20px;
}

a {
    color: #0000cc;
    text-decoration: underline;
}

a:visited {
    color: #660099;
}

a:hover {
    color: #cc0000;
    background-color: #ffff88;
}

/* ================= ВЕРХНЯЯ БЕГУЩАЯ СТРОКА ================= */
.top-marquee {
    background: #000080;
    color: #ffff00;
    padding: 5px 0;
    font-family: 'Courier New', monospace;
    font-weight: bold;
    font-size: 13px;
    overflow: hidden;
    white-space: nowrap;
    border-bottom: 2px solid #000000;
    border-top: 2px solid #000000;
}

.top-marquee span {
    display: inline-block;
    padding-left: 100%;
    animation: marquee 30s linear infinite;
}

@keyframes marquee {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-100%); }
}

/* ================= ОБЩАЯ ОБЁРТКА ================= */
.page-wrapper {
    max-width: 900px;
    margin: 20px auto;
    background: #f0f0e0;
    border: 3px ridge #808080;
    padding: 15px 20px 20px;
    box-shadow: 4px 4px 0 #808080;
}

/* ================= ШАПКА ================= */
.site-header {
    text-align: center;
    padding: 15px 10px 20px;
    background: linear-gradient(180deg, #ffffff 0%, #d0e0d0 100%);
    border: 2px inset #a0a0a0;
    margin-bottom: 15px;
}

.site-header h1 {
    margin: 0 0 5px;
    font-family: 'Comic Sans MS', 'Times New Roman', cursive;
    font-size: 32px;
    color: #800000;
    text-shadow: 2px 2px 0 #ffff00, 4px 4px 0 #00000022;
    letter-spacing: 1px;
}

.site-subtitle {
    margin: 0 0 8px;
    font-family: 'Courier New', monospace;
    font-size: 16px;
    color: #006600;
    font-weight: bold;
    letter-spacing: 3px;
}

.site-tagline {
    margin: 0;
    font-size: 14px;
    color: #333333;
}

/* Мерцающий текст */
.blink {
    color: #ff0000;
    font-weight: bold;
    animation: blink 1s steps(2, start) infinite;
}

@keyframes blink {
    50% { opacity: 0; }
}

/* ================= НАВИГАЦИЯ ================= */
.site-nav {
    text-align: center;
    padding: 10px;
    background: #e8e8d8;
    border: 2px dashed #808080;
    margin-bottom: 10px;
    font-family: 'Courier New', monospace;
    font-size: 14px;
}

.site-nav a {
    margin: 0 8px;
    font-weight: bold;
    text-decoration: none;
}

.site-nav a:hover {
    background: #ffff00;
    color: #000000;
}

/* ================= РАЗДЕЛИТЕЛЬ ================= */
.fancy-hr {
    border: none;
    border-top: 3px double #006600;
    margin: 20px 0;
    height: 0;
}

/* ================= СЕКЦИИ ================= */
.legacy-section {
    margin-bottom: 20px;
    padding: 0 5px;
}

.section-title {
    font-family: 'Times New Roman', serif;
    font-size: 22px;
    color: #800000;
    text-align: center;
    background: #ffffcc;
    border: 2px solid #800000;
    padding: 6px 10px;
    margin: 0 0 15px;
    text-shadow: 1px 1px 0 #ffffff;
}

/* ================= ТАБЛИЦЫ ================= */
.info-table {
    border-collapse: collapse;
    border: 2px solid #000080;
    font-size: 15px;
    margin-bottom: 15px;
    background: #ffffff;
}

.info-table td {
    border: 1px solid #a0a0a0;
    padding: 8px 10px;
    vertical-align: top;
}

.info-label {
    background: #e0e8d0;
    color: #004400;
}

/* Ник-бейдж */
.nick-badge {
    display: inline-block;
    background: #000080;
    color: #ffff00;
    font-family: 'Courier New', monospace;
    font-weight: bold;
    padding: 2px 8px;
    border: 1px outset #4040a0;
}

/* ================= ТЕКСТ ================= */
.legacy-text {
    font-size: 15px;
    margin: 0 0 10px;
    text-align: justify;
}

.legacy-text.center {
    text-align: center;
}

/* ================= ПРОЕКТЫ ================= */
.legacy-project {
    background: #f8f8f0;
    border: 2px groove #a0a0a0;
    padding: 12px 15px;
    margin-bottom: 20px;
}

.legacy-project h3 {
    margin: 0 0 8px;
    color: #000080;
    font-size: 18px;
    font-family: 'Courier New', monospace;
    border-bottom: 1px dashed #808080;
    padding-bottom: 6px;
}

.version-badge {
    display: inline-block;
    font-size: 11px;
    background: #ffcc00;
    color: #000000;
    padding: 1px 6px;
    border: 1px solid #000000;
    font-family: 'Courier New', monospace;
    font-weight: bold;
    vertical-align: middle;
}

/* ================= ИНСТРУКЦИЯ ================= */
.instruction-box {
    background: #fffff0;
    border: 2px dashed #006600;
    padding: 12px 15px;
    margin: 12px 0;
    font-size: 14px;
}

.instruction-box h4 {
    margin: 0 0 10px;
    color: #006600;
    font-family: 'Courier New', monospace;
}

.instruction-box ol {
    margin: 0 0 10px;
    padding-left: 25px;
}

.instruction-box li {
    margin-bottom: 5px;
}

.instruction-box code {
    background: #e0e0e0;
    border: 1px solid #808080;
    padding: 1px 5px;
    font-family: 'Courier New', monospace;
    font-size: 13px;
    color: #000080;
}

.success-line {
    background: #e0ffe0;
    border-left: 4px solid #008000;
    padding: 6px 10px;
    margin: 10px 0 6px;
    font-size: 14px;
}

.note-line {
    background: #fff0e0;
    border-left: 4px solid #cc6600;
    padding: 6px 10px;
    margin: 0;
    font-size: 14px;
}

kbd {
    display: inline-block;
    background: #f0f0f0;
    border: 1px solid #808080;
    border-bottom-width: 3px;
    padding: 1px 6px;
    font-family: 'Courier New', monospace;
    font-size: 12px;
    font-weight: bold;
}

/* ================= СПИСКИ ================= */
.legacy-list {
    margin: 10px 0;
    padding-left: 30px;
    list-style-type: square;
}

.legacy-list li {
    margin-bottom: 3px;
}

/* ================= КНОПКИ ================= */
.btn-row {
    margin: 12px 0 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.legacy-btn {
    display: inline-block;
    padding: 6px 14px;
    font-family: 'Courier New', monospace;
    font-size: 13px;
    font-weight: bold;
    text-decoration: none;
    color: #000080;
    background: linear-gradient(180deg, #ffffff 0%, #d0d0d0 100%);
    border: 2px outset #c0c0c0;
    cursor: pointer;
    transition: none;
}

.legacy-btn:hover {
    background: #ffff88;
    color: #cc0000;
    border-style: inset;
}

.legacy-btn:active {
    border-style: inset;
    transform: translateY(1px);
}

.legacy-btn-primary {
    background: linear-gradient(180deg, #c0e0c0 0%, #80b080 100%);
    color: #000000;
    border-color: #80a080;
}

.legacy-btn-primary:hover {
    background: #ffff88;
    color: #000080;
}

/* ================= СПОНСОРЫ (кнопки 88×31) ================= */
.sponsor-buttons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: flex-start;
    gap: 20px;
    margin: 15px 0;
}

.sponsor-btn-wrap {
    text-align: center;
    padding: 8px 12px;
    background: #f0f0e0;
    border: 2px groove #c0c0c0;
    min-width: 130px;
}

.sponsor-btn-wrap img {
    display: block;
    margin: 0 auto 6px;
    border: 1px solid #808080;
    max-width: 100%;
    image-rendering: pixelated;
}

.sponsor-btn-wrap p,
.sponsor-btn-wrap .sponsor-caption {
    margin: 0;
    font-size: 12px;
    font-family: 'Courier New', monospace;
    color: #333333;
}

/* ================= СЧЁТЧИК ================= */
.counter-box {
    text-align: center;
    margin: 20px auto;
    padding: 12px;
    background: #000000;
    border: 3px ridge #808080;
    max-width: 340px;
    color: #00ff00;
}

.counter-box p {
    margin: 0 0 8px;
    font-family: 'Courier New', monospace;
    font-size: 14px;
    color: #ffff00;
}

.counter-digits {
    display: inline-flex;
    gap: 3px;
}

.counter-digits span {
    display: inline-block;
    width: 24px;
    height: 34px;
    line-height: 34px;
    background: #111111;
    color: #00ff00;
    font-family: 'Courier New', monospace;
    font-size: 20px;
    font-weight: bold;
    text-align: center;
    border: 1px solid #00aa00;
    box-shadow: inset 0 0 4px #00ff00;
}

.counter-note {
    font-size: 11px;
    color: #888888 !important;
    margin-top: 6px !important;
}

/* ================= НАВЕРХ ================= */
.back-top {
    text-align: center;
    margin: 15px 0;
}

.back-top a {
    font-family: 'Courier New', monospace;
    font-size: 13px;
    font-weight: bold;
    color: #000080;
}

/* ================= ПОДВАЛ ================= */
.site-footer {
    margin-top: 25px;
    padding: 15px 10px;
    background: #e8e8d8;
    border-top: 3px double #006600;
    text-align: center;
    font-size: 13px;
}

.site-footer p {
    margin: 0 0 8px;
}

.site-footer .footer-small {
    font-size: 11px;
    color: #555555;
    line-height: 1.5;
}

.footer-badges {
    margin-top: 10px !important;
}

.badge {
    display: inline-block;
    font-family: 'Courier New', monospace;
    font-size: 10px;
    background: #000080;
    color: #ffff00;
    padding: 2px 8px;
    margin: 2px;
    border: 1px outset #4040a0;
}

/* ================= АДАПТИВ ================= */
@media (max-width: 700px) {
    .page-wrapper {
        margin: 10px;
        padding: 10px 12px;
    }
    .site-header h1 {
        font-size: 22px;
    }
    .site-subtitle {
        font-size: 13px;
        letter-spacing: 1px;
    }
    .section-title {
        font-size: 18px;
    }
    .legacy-project {
        padding: 10px;
    }
    .sponsor-btn-wrap {
        min-width: 110px;
        padding: 6px 8px;
    }
    .top-marquee {
        font-size: 11px;
    }
}