/* ==========================================================================
   Стили главной страницы сайта remont-aud.net (Префикс .home-)
   ========================================================================== */

/* 1. Основной двухколоночный контейнер */
.home-container {
    display: flex;
    gap: 20px;
    width: 100%;
    margin: 20px 0;
    align-items: flex-start;
}

.home-main-col {
    flex: 0 0 calc(70% - 10px);
    max-width: calc(70% - 10px);
    min-width: 0;
}

.home-side-col {
    flex: 0 0 calc(30% - 10px);
    max-width: calc(30% - 10px);
    min-width: 0;
}

/* 2. Приветственный блок (Hero) */
.home-hero {
    margin-bottom: 20px;
}

.home-hero-title {
    font-size: 24px;
    color: #174569;
    font-weight: 700;
    margin: 0 0 15px 0;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.9);
}

/* 3. Четыре крупные плитки разделов */
.home-tiles {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    margin-bottom: 25px;
}

.home-tile {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 16px 10px;
    background: #ffffff;
    border-radius: 6px;
    text-decoration: none;
    border-bottom: 4px solid #afbfcb;
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.home-tile:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(23, 69, 105, 0.15);
    border-bottom-color: #174572;
}

.home-tile-icon {
    font-size: 30px;
    color: #174572;
    margin-bottom: 8px;
    transition: color 0.2s ease;
}

.home-tile:hover .home-tile-icon {
    color: #23699e;
}

.home-tile-title {
    font-size: 15px;
    font-weight: 600;
    color: #174569;
    line-height: 1.25;
}

/* 4. Карточки информационных блоков */
.home-block {
    margin-bottom: 25px;
}

.home-block-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    background: url(/images/stripe.png) bottom center repeat-x;
    height: 26px;
}

.home-block-title {
    font-size: 22px;
    font-weight: 600;
    background: #F2F2F2;
    color: #174569;
    padding: 0 10px 0 0;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    line-height: 24px;
}

.home-block-title i {
    font-size: 18px;
    color: #23699e;
}

.home-block-more {
    background: #F2F2F2;
    padding: 0 0 0 10px;
    font-size: 13px;
    font-weight: 600;
    color: #174572;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    line-height: 24px;
    transition: color 0.2s ease;
}

.home-block-more:hover {
    color: #0b263e;
    text-decoration: underline;
}

.home-block-card {
    background: #ffffff;
    border-bottom: 4px solid #afbfcb;
    box-shadow: 0 0 3px #CACACA;
    border-radius: 4px;
    overflow: hidden;
}

/* 5. Элементы списка форума */
.home-topic-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    border-bottom: 1px solid #edf2f7;
    transition: background-color 0.15s ease;
}

.home-topic-item:last-child {
    border-bottom: none;
}

.home-topic-item:hover {
    background-color: #f7f9fc;
}

.home-topic-main {
    flex: 1;
    min-width: 0;
    padding-right: 15px;
}

.home-topic-title {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.35;
    margin-bottom: 4px;
    word-break: break-word;
}

.home-topic-title a {
    color: #174569;
    text-decoration: none;
}

.home-topic-title a:hover {
    color: #081824;
    text-decoration: underline;
}

.home-topic-meta {
    font-size: 12px;
    color: #718096;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.home-topic-section {
    background: #eaf1f7;
    color: #174569;
    padding: 2px 6px;
    border-radius: 3px;
    font-weight: 500;
    font-size: 11px;
    text-decoration: none;
    white-space: nowrap;
}

.home-topic-section:hover {
    background: #d5e5f2;
    color: #0b263e;
}

.home-topic-author {
    color: #4a5568;
    font-weight: 500;
}

.home-topic-date {
    color: #8e93ab;
}

.home-topic-stats {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 12px;
    color: #555;
    white-space: nowrap;
    flex-shrink: 0;
    background: #f7fafc;
    padding: 4px 8px;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
}

.home-topic-stats i {
    color: #718096;
}

/* 6. Элементы списка материалов (Файлы, Статьи, Объявления) */
.home-mat-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    border-bottom: 1px solid #edf2f7;
    transition: background-color 0.15s ease;
}

.home-mat-item:last-child {
    border-bottom: none;
}

.home-mat-item:hover {
    background-color: #f7f9fc;
}

.home-mat-main {
    flex: 1;
    min-width: 0;
    padding-right: 15px;
}

.home-mat-title {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.35;
    margin-bottom: 3px;
    word-break: break-word;
}

.home-mat-title a {
    color: #174569;
    text-decoration: none;
}

.home-mat-title a:hover {
    color: #081824;
    text-decoration: underline;
}

.home-mat-meta {
    font-size: 12px;
    color: #718096;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.home-mat-cat {
    background: #eef2f6;
    color: #23699e;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: 500;
    text-decoration: none;
    white-space: nowrap;
}

.home-mat-cat:hover {
    background: #dde7f0;
    color: #174572;
}

.home-mat-date {
    color: #8e93ab;
    font-size: 12px;
    white-space: nowrap;
    flex-shrink: 0;
}

/* 7. Боковая колонка: виджет «Сейчас на сайте» */
.home-online-stats {
    font-size: 13px;
    line-height: 1.6;
    color: #333;
    padding: 12px 14px;
    border-bottom: 1px solid #edf2f7;
    background: #fdfdfd;
}

.home-online-stats strong {
    color: #174569;
}

.home-online-list {
    padding: 12px 14px;
    font-size: 13px;
    line-height: 1.8;
    word-break: break-word;
}

.home-online-list a {
    margin-right: 4px;
    display: inline-block;
    font-weight: 500;
    text-decoration: none;
}

.home-online-list a:hover {
    text-decoration: underline;
}

.home-online-footer {
    padding: 8px 14px 12px;
    text-align: right;
    border-top: 1px dashed #e2e8f0;
}

.home-online-full-btn {
    font-size: 12px;
    color: #174569;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
}

.home-online-full-btn:hover {
    text-decoration: underline;
}

/* 8. Боковая колонка: виджет «Топ загрузчиков» */
.home-uploader-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 14px;
    border-bottom: 1px solid #edf2f7;
    transition: background-color 0.15s ease;
}

.home-uploader-item:last-child {
    border-bottom: none;
}

.home-uploader-item:hover {
    background-color: #f7f9fc;
}

.home-uploader-user {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.home-uploader-avatar {
    width: 28px;
    height: 28px;
    border-radius: 4px;
    object-fit: cover;
    flex-shrink: 0;
}

.home-uploader-avatar-placeholder {
    width: 28px;
    height: 28px;
    border-radius: 4px;
    background: #b7cad3;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
    flex-shrink: 0;
}

.home-uploader-name {
    font-size: 13px;
    font-weight: 600;
    color: #174569;
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 180px;
}

.home-uploader-name:hover {
    color: #081824;
    text-decoration: underline;
}

.home-uploader-badge {
    font-size: 12px;
    font-weight: 600;
    color: #174572;
    background: #edf4f9;
    padding: 2px 8px;
    border-radius: 10px;
    white-space: nowrap;
    flex-shrink: 0;
}

/* 9. Адаптивность (Медиа-запросы проекта) */
@media (max-width: 1300px) {
    .home-hero-title {
        font-size: 22px;
    }
}

@media (max-width: 991px) {
    .home-container {
        flex-direction: column;
    }

    .home-main-col,
    .home-side-col {
        flex: 0 0 100%;
        max-width: 100%;
        width: 100%;
    }
}

@media (max-width: 575px) {
    .home-hero-title {
        font-size: 19px;
        margin-bottom: 12px;
    }

    .home-tiles {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        margin-bottom: 20px;
    }

    .home-tile {
        padding: 12px 8px;
    }

    .home-tile-icon {
        font-size: 24px;
        margin-bottom: 6px;
    }

    .home-tile-title {
        font-size: 13px;
    }

    .home-block-title {
        font-size: 18px;
    }

    .home-topic-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .home-topic-main {
        padding-right: 0;
        width: 100%;
    }

    .home-topic-stats {
        align-self: flex-start;
    }

    .home-mat-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .home-mat-main {
        padding-right: 0;
        width: 100%;
    }

    .home-mat-date {
        align-self: flex-start;
    }
}
