/* Компоненты главной — серверы, кланы, бегущая строка, devlog-блок */

/* ── Marquee ── */
.marquee-wrapper {
    margin-bottom: 2rem;
}

.marquee-container {
    position: relative;
    overflow: hidden;
    padding: 0.85rem 0;
    border-radius: var(--radius, 14px);
    background: rgba(10, 16, 30, 0.55);
    border: 1px solid var(--border, rgba(255, 255, 255, 0.08));
}

.marquee-container::before,
.marquee-container::after {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    width: 72px;
    z-index: 2;
    pointer-events: none;
}

.marquee-container::before {
    left: 0;
    background: linear-gradient(90deg, rgba(6, 11, 20, 1), transparent);
}

.marquee-container::after {
    right: 0;
    background: linear-gradient(270deg, rgba(6, 11, 20, 1), transparent);
}

.marquee-track {
    display: inline-block;
    white-space: nowrap;
    animation: home-marquee 28s linear infinite;
}

.marquee-content {
    display: inline-block;
    white-space: nowrap;
}

.marquee-content span {
    display: inline-block;
    padding: 0 1.75rem;
    font-size: 0.92rem;
    font-weight: 500;
    color: rgba(238, 242, 248, 0.88);
    letter-spacing: 0.04em;
}

@keyframes home-marquee {
    from { transform: translateX(0); }
    to { transform: translateX(-33.333%); }
}

/* ── Server cards ── */
.server-card {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.server-card-body {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    min-width: 0;
}

.server-card-icon {
    width: 52px;
    height: 52px;
    flex-shrink: 0;
    border-radius: 10px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border, rgba(255, 255, 255, 0.08));
}

.server-card-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.server-card-icon .default-icon {
    width: 100%;
    height: 100%;
    background: url("https://i.yapx.ru/dRNNO.png") center / 70% no-repeat;
    filter: brightness(0) invert(1);
    opacity: 0.75;
}

.server-card-info {
    flex: 1;
    min-width: 0;
}

.server-card-status {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    flex-wrap: wrap;
}

.status-online {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.78rem;
    font-weight: 500;
    color: #5dffa0;
}

.online-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #3dff8a;
    box-shadow: 0 0 6px rgba(61, 255, 138, 0.45);
}

.players-count {
    font-size: 0.72rem;
    color: var(--text-muted, rgba(238, 242, 248, 0.48));
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.server-card-connect-row {
    display: flex;
    align-items: stretch;
    gap: 0.5rem;
    min-width: 0;
}

.server-card-connect-code {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ── Clan carousel cards ── */
.clans-section .clan-card {
    padding: 1.15rem 1rem;
    height: 100%;
    overflow: hidden;
}

.clans-section .clan-link {
    display: block;
    height: 100%;
    text-decoration: none;
    color: inherit;
}

.clans-section .clan-card-inner {
    position: relative;
    z-index: 1;
}

.clans-section .clan-icon {
    width: 72px;
    height: 72px;
    margin: 0 auto 0.85rem;
    position: relative;
    flex-shrink: 0;
}

.clans-section .clan-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    border-radius: 12px;
    background: rgba(42, 129, 255, 0.06);
    padding: 0.35rem;
}

.clans-section .icon-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: rgba(42, 129, 255, 0.08);
    border: 1px solid rgba(42, 129, 255, 0.18);
}

.clans-section .icon-placeholder i {
    font-size: 1.65rem;
    color: rgba(77, 216, 255, 0.65);
    line-height: 1;
}

.clans-section .clan-info {
    text-align: center;
}

.clans-section .clan-name {
    margin: 0 0 0.4rem;
    font-size: 0.95rem;
}

.clans-section .clan-description {
    margin: 0;
    font-size: 0.8rem;
    line-height: 1.45;
    color: var(--text-muted, rgba(238, 242, 248, 0.48));
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.clans-section .clan-glow {
    display: none;
}

/* ── Home devlog block ── */
.home-devlog-section__head {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.home-devlog-section__title {
    margin: 0;
    font-size: clamp(1.15rem, 2.4vw, 1.45rem);
    font-weight: 500;
    color: rgba(238, 242, 248, 0.94);
}

.home-devlog-section__link-all {
    color: #9fd4ff;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
}

.home-devlog-section__link-all:hover {
    color: #fff;
}

.home-devlog-feature {
    display: block;
    text-decoration: none;
    color: inherit;
    position: relative;
    overflow: hidden;
    border: 1px solid var(--border, rgba(255, 255, 255, 0.08));
    border-radius: 16px;
    background: rgba(10, 16, 28, 0.72);
    transition: border-color 0.2s, background 0.2s;
}

.home-devlog-feature:hover {
    border-color: rgba(42, 129, 255, 0.28);
    background: rgba(14, 22, 38, 0.88);
}

.home-devlog-feature__inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem 1.15rem;
    flex-wrap: wrap;
}

.home-devlog-feature__glow {
    display: none;
}

.home-devlog-feature__title {
    margin: 0 0 0.45rem;
    font-size: 1.05rem;
    font-weight: 500;
}

.home-devlog-feature__excerpt {
    margin: 0 0 0.65rem;
    color: var(--text-muted, rgba(238, 242, 248, 0.48));
    font-size: 0.88rem;
    line-height: 1.55;
}

.home-devlog-feature__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin-bottom: 0.65rem;
}

.home-devlog-feature__tag {
    font-size: 0.72rem;
    padding: 0.2rem 0.5rem;
    border-radius: 999px;
    background: rgba(42, 129, 255, 0.1);
    border: 1px solid rgba(42, 129, 255, 0.22);
    color: #b8d9ff;
}

.home-devlog-feature__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    flex-wrap: wrap;
    font-size: 0.8rem;
    color: var(--text-muted, rgba(238, 242, 248, 0.48));
}

.home-devlog-feature__author {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

.home-devlog-feature__author-img {
    border-radius: 50%;
    object-fit: cover;
}

.home-devlog-feature__cta-btn {
    display: inline-flex;
    align-items: center;
    padding: 0.45rem 0.85rem;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 500;
    color: #d4e8ff;
    background: rgba(42, 129, 255, 0.12);
    border: 1px solid rgba(42, 129, 255, 0.28);
}

@media (max-width: 700px) {
    .home-devlog-feature__inner {
        flex-direction: column;
        align-items: flex-start;
    }

    .server-card-connect-row {
        flex-direction: column;
    }

    .server-card-connect-code {
        white-space: normal;
        overflow-wrap: anywhere;
    }
}
