:root {
    --bg-deep: #0a0a1a;
    --bg-teal: #0f3d5c;
    --glass-bg: rgba(20, 20, 40, 0.6);
    --glass-border: rgba(255, 255, 255, 0.1);
    --accent-cyan: #00ffff;
    --accent-purple: #6c48b8;
    --text-white: #ffffff;
    --text-dim: #aaffff;
    --online-green: #57cbde;
    --lvl-circle: #4e8dd1;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, var(--bg-deep) 0%, var(--bg-teal) 100%);
    background-attachment: fixed;
    color: var(--text-white);
    overflow-x: hidden;
    min-height: 100vh;
}

/* Bubbles Background Animation */
.bubbles-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

.bubble {
    position: absolute;
    bottom: -50px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    box-shadow: inset 0 0 10px rgba(255, 255, 255, 0.2);
    animation: rise 15s infinite ease-in;
}

@keyframes rise {
    0% { transform: translateY(0) scale(1); opacity: 0; }
    10% { opacity: 0.5; }
    90% { opacity: 0.5; }
    100% { transform: translateY(-120vh) scale(1.5); opacity: 0; }
}

/* Glassmorphism Common */
.glass {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);

    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Profile Header */
.profile-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 30px;
    flex-wrap: wrap;
    gap: 20px;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.avatar-container {
    position: relative;
    width: 120px;
    height: 120px;
    border: 3px solid var(--accent-cyan);
    border-radius: 8px;
    padding: 2px;
}

.main-avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 4px;
}

.status-indicator {
    position: absolute;
    bottom: -5px;
    right: -5px;
    width: 20px;
    height: 20px;
    background: var(--online-green);
    border-radius: 50%;
    border: 3px solid #1a1a2e;
}

.username-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.username-row h1 {
    font-size: 2.5rem;
    font-weight: 700;
}

.dropdown-arrow {
    font-size: 0.8rem;
    opacity: 0.6;
    cursor: pointer;
}

.location {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 5px;
    color: var(--text-dim);
}

.flag {
    width: 20px;
    height: auto;
}

.header-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 15px;
}

.level-badge {
    display: flex;
    align-items: center;
    gap: 10px;
}

.level-circle {
    width: 50px;
    height: 50px;
    border: 2px solid var(--lvl-circle);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.2rem;
    box-shadow: 0 0 10px var(--lvl-circle);
}

.level-label {
    font-size: 1.1rem;
    font-weight: 600;
}

.exp-container {
    width: 240px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.exp-label {
    font-size: 0.85rem;
    color: var(--text-dim);
}

.exp-bar {
    width: 100%;
    height: 8px;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 4px;
    overflow: hidden;
}

.exp-fill {
    height: 100%;
}

.edit-profile-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 8px 20px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.2s;
}

.edit-profile-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.05);
}

/* Hero Banner */
.hero-banner {
    width: 100%;
    height: 300px;
    position: relative;
    overflow: hidden;
}

.hero-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, transparent 0%, rgba(10, 10, 26, 0.8) 100%);
}

/* Columns Layout */
.content-columns {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
}

@media (max-width: 900px) {
    .content-columns {
        grid-template-columns: 1fr;
    }
}

/* Blocks General */
.newsfeed-block, .status-block, .badges-block, .menu-block, .stats-block, .friends-block {
    padding: 0;
    margin-bottom: 20px;
    overflow: hidden;
}

.block-header {
    background: rgba(108, 72, 184, 0.3);
    padding: 10px 20px;
    border-bottom: 1px solid var(--glass-border);
}

.block-header h2, .block-header h3 {
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.scroll-container {
    max-height: 400px;
    overflow-y: auto;
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* Custom Scrollbar */
.scroll-container::-webkit-scrollbar {
    width: 6px;
}
.scroll-container::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
}

/* Comment Item */
.comment-card {
    background: rgba(0, 0, 0, 0.2);
    padding: 15px;
    border-radius: 8px;
    display: flex;
    gap: 15px;
    transition: transform 0.2s;
}

.comment-card:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateX(5px);
}

.comment-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.comment-content {
    flex: 1;
}

.comment-top {
    display: flex;
    justify-content: space-between;
    margin-bottom: 5px;
}

.comment-author {
    font-weight: 600;
    color: var(--accent-cyan);
}

.comment-time {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
}

.comment-text {
    font-size: 0.95rem;
    line-height: 1.4;
}

.comment-actions {
    margin-top: 10px;
    display: flex;
    gap: 15px;
    font-size: 0.85rem;
    opacity: 0.7;
}

.comment-actions span {
    cursor: pointer;
}

.comment-actions span:hover {
    color: var(--accent-cyan);
}

/* Wall Input */
.post-input-area {
    padding: 15px;
    background: rgba(0, 0, 0, 0.3);
}

#post-content {
    width: 100%;
    height: 80px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    color: white;
    padding: 10px;
    resize: none;
    font-family: inherit;
    margin-bottom: 10px;
}

.submit-btn {
    background: var(--accent-purple);
    color: white;
    border: none;
    padding: 8px 25px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
}

.submit-btn:hover {
    filter: brightness(1.2);
}

/* Right Column Blocks */
.status-block {
    padding: 15px 20px;
}

.status-title {
    color: #8c8c8c;
    font-size: 1.5rem;
    font-weight: 300;
    margin-bottom: 5px;
}

.status-subtitle {
    font-size: 0.85rem;
    color: #8c8c8c;
    margin-bottom: 10px;
}

.status-links a {
    color: var(--accent-cyan);
    text-decoration: underline;
    font-size: 0.85rem;
    margin-right: 15px;
}

.badges-row {
    display: flex;
    gap: 10px;
    padding: 15px;
    justify-content: center;
}

.badge-item img {
    width: 50px;
    height: 50px;
    transition: transform 0.3s;
    cursor: help;
}

.badge-item:hover img {
    transform: scale(1.2) rotate(5deg);
    filter: drop-shadow(0 0 8px var(--accent-cyan));
}

/* Menu */
.menu-header {
    text-align: center;
    padding: 10px;
    font-weight: 700;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.menu-list {
    list-style: none;
}

.menu-list li {
    padding: 12px 20px;
    display: flex;
    align-items: center;
    cursor: pointer;
    transition: background 0.2s;
}

.menu-list li:hover {
    background: rgba(255, 255, 255, 0.05);
}

.menu-icon {
    width: 25px;
    margin-right: 15px;
    font-size: 1.2rem;
}

.menu-list .count {
    margin-left: auto;
    color: #8c8c8c;
    font-size: 0.9rem;
}

/* Stats */
.stats-block {
    padding: 20px;
}

.stats-title-main, .stats-subtitle-main {
    font-weight: 700;
    margin-bottom: 15px;
}

.stats-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
    margin: 15px 0;
}

.stat-list {
    list-style: none;
}

.stat-list li {
    margin-bottom: 8px;
    font-size: 0.9rem;
    color: var(--text-dim);
    display: flex;
    justify-content: space-between;
}

.stat-list .val {
    color: white;
    font-weight: 600;
}

/* Friends */
.friends-list {
    display: flex;
    flex-direction: column;
}

.friend-item {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    gap: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: background 0.2s;
}

.friend-item:hover {
    background: rgba(255, 255, 255, 0.05);
}

.friend-avatar {
    width: 38px;
    height: 38px;
    border-radius: 4px;
}

.friend-info {
    flex: 1;
}

.friend-name {
    font-weight: 600;
    font-size: 0.95rem;
}

.friend-status {
    font-size: 0.8rem;
    color: #8c8c8c;
}

.friend-status.in-game {
    color: var(--online-green);
}

.friend-lvl {
    width: 32px;
    height: 32px;
    border: 2px solid;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
}

.lvl-purple { border-color: #d14ed1; box-shadow: 0 0 5px #d14ed1; }
.lvl-orange { border-color: #d18d4e; box-shadow: 0 0 5px #d18d4e; }
.lvl-red { border-color: #d14e4e; box-shadow: 0 0 5px #d14e4e; }
.lvl-blue { border-color: #4e8dd1; box-shadow: 0 0 5px #4e8dd1; }
.lvl-green { border-color: #4ed18d; box-shadow: 0 0 5px #4ed18d; }
.lvl-grey { border-color: #8c8c8c; box-shadow: 0 0 5px #8c8c8c; }

.load-more-btn {
    width: 100%;
    padding: 10px;
    background: transparent;
    border: none;
    color: var(--accent-cyan);
    cursor: pointer;
    font-size: 0.9rem;
    transition: background 0.2s;
}

.load-more-btn:hover {
    background: rgba(255, 255, 255, 0.05);
}

.loading-placeholder {
    padding: 20px;
    text-align: center;
    color: var(--text-dim);
}
.profile-settings-wrapper {
    padding: 40px 20px;
    max-width: 800px;
    margin: 0 auto;
}

.profile-settings-wrapper h1 {
    text-align: center;
    margin-bottom: 30px;
    font-size: 2rem;
}

.profile-settings-success {
    background: rgba(0, 255, 150, 0.1);
    border-left: 4px solid #00ff96;
    padding: 10px 15px;
    margin-bottom: 20px;
    font-weight: bold;
    color: #00ff96;
    border-radius: 10px;
}

.profile-settings-form .form-group {
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
}

.profile-settings-form .form-group label {
    font-weight: bold;
    margin-bottom: 5px;
}

.profile-settings-form .form-group input[type="url"],
.profile-settings-form .form-group input[type="text"] {
    padding: 10px;
    border-radius: 12px;
    border: none;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(8px);
    color: #fff;
}

.profile-settings-form .form-group input[type="checkbox"] {
    margin-right: 10px;
}

.profile-settings-form .btn-submit {
    background: rgba(0, 255, 150, 0.25);
    border: none;
    padding: 12px 25px;
    border-radius: 15px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
}

.profile-settings-form .btn-submit:hover {
    background: rgba(0, 255, 150, 0.5);
}
/* =================================
   Стили для блока "Комментарии к записям"
   ================================= */

/* Карточка отдельного комментария */
#user-comments-list .user-comment-item {
    background: rgba(0, 0, 0, 0.2);
    padding: 15px 20px;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    gap: 12px; /* Расстояние между элементами внутри карточки */
    border-left: 3px solid transparent; /* Для акцента при наведении */
    transition: all 0.3s ease;
}

#user-comments-list .user-comment-item:hover {
    background: rgba(0, 0, 0, 0.3);
    border-left-color: var(--accent-cyan);
    transform: translateX(5px);
}

/* Мета-информация (ссылка на пост и дата) */
#user-comments-list .comment-item-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85em;
    color: var(--text-dim);
    opacity: 0.8;
}

#user-comments-list .comment-item-meta a {
    color: var(--text-dim);
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s;
}

#user-comments-list .comment-item-meta a:hover {
    color: var(--accent-cyan);
    text-decoration: underline;
}

/* Текст самого комментария (отрывок) */
#user-comments-list .comment-item-content {
    color: var(--text-white);
    line-height: 1.5;
    font-size: 0.95rem;
}

/* Кнопка "Перейти к комментарию" */
#user-comments-list .comment-goto-btn {
    display: inline-block;
    background: var(--accent-purple);
    color: white;
    padding: 8px 15px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.8rem;
    align-self: flex-start; /* Кнопка будет в начале блока */
    transition: filter 0.2s;
    border: none;
    cursor: pointer;
}

#user-comments-list .comment-goto-btn:hover {
    filter: brightness(1.25);
}

/* Убираем лишний отступ у контейнера, если он есть */
.newsfeed-block .scroll-container {
    padding-top: 5px;
}
/* =================================
   Стили для пагинации комментариев
   ================================= */

.pagination-links {
    padding: 20px;
    background: rgba(0, 0, 0, 0.2);
    border-top: 1px solid var(--glass-border);
}

.pagination-links .page-numbers {
    list-style: none;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin: 0;
    padding: 0;
}

.pagination-links .page-numbers li {
    margin: 0;
}

.pagination-links .page-numbers a,
.pagination-links .page-numbers span {
    display: block;
    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 6px;
    color: var(--text-dim);
    text-decoration: none;
    transition: all 0.2s ease;
}

.pagination-links .page-numbers a:hover {
    background: var(--accent-purple);
    color: var(--text-white);
    border-color: transparent;
}

.pagination-links .page-numbers .current {
    background: var(--accent-cyan);
    color: var(--bg-deep);
    border-color: var(--accent-cyan);
    font-weight: 700;
}

/* Стили для точек "..." */
.pagination-links .page-numbers .dots {
    background: transparent;
    border: none;
    padding: 8px 0;
}
/* =================================
   Стили для блока ссылок в профиле
   ================================= */

.profile-links-block {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Ссылка на Steam */
.profile-link-item {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 12px;
    background: rgba(0, 0, 0, 0.25);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    color: var(--text-white);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s ease;
}

.profile-link-item:hover {
    background: var(--accent-purple);
    color: var(--text-white);
    border-color: var(--accent-purple);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(108, 72, 184, 0.4);
}

.profile-link-item svg {
    transition: transform 0.2s ease;
}

.profile-link-item:hover svg {
    transform: scale(1.1);
}

/* Блок "Ссылка на профиль" */
.share-link-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.share-link-item label {
    font-size: 0.9em;
    font-weight: 600;
    color: var(--text-dim);
    opacity: 0.9;
}

.share-link-item input[type="text"] {
    width: 100%;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid var(--glass-border);
    border-radius: 6px;
    padding: 10px;
    color: var(--text-white);
    font-family: inherit;
    font-size: 0.9em;
    cursor: pointer;
    text-align: center;
}
/* =================================
   Стили для блока статистики игрока
   ================================= */

.profile-stats-block {
    display: flex;
    flex-direction: column;
    margin-top: 20px;
}

.stats-content {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 15px; /* Расстояние между заголовком и списком */
}

.stats-content h3 {
    margin: 0;
    font-size: 1rem;
    color: var(--text-white);
    text-transform: uppercase;
    letter-spacing: 1px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--glass-border);
    opacity: 0.9;
}

.stats-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 12px; /* Расстояние между строками статистики */
}

.stat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0, 0, 0, 0.2);
    padding: 10px 15px;
    border-radius: 6px;
}

.stat-label {
    color: var(--text-dim);
    opacity: 0.8;
    font-size: 0.9em;
}

.stat-value {
    color: var(--text-white);
    font-weight: 700;
    font-size: 1em;
}
/* =================================
   Стили для онлайн-статуса
   ================================= */

/* Зеленый цвет для текста "В сети" */
.status-title.online {
    color: var(--online-green); /* Используем вашу переменную */
}

/* Стиль для индикатора, КОГДА пользователь онлайн */
.status-indicator.online {
    background-color: var(--online-green);
    /* Добавляем красивое свечение */
    box-shadow: 0 0 10px 1px var(--online-green);
}
/* ===============================================================
   СТИЛИ ДЛЯ СТЕНЫ (КОММЕНТАРИИ К ПРОФИЛЮ)
   =============================================================== */

/* Форма добавления комментария */
.profile-comment-form {
    padding: 15px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.profile-comment-form form {
    display: flex;
    flex-direction: column;
}

.profile-comment-form textarea {
    width: 100%;
    min-height: 80px;
    background-color: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: #fff;
    padding: 10px;
    margin-bottom: 10px;
    font-family: inherit;
    resize: vertical;
    transition: all 0.3s ease;
}

.profile-comment-form textarea:focus {
    outline: none;
    border-color: var(--neon-accent, #00f2ff);
    box-shadow: 0 0 10px rgba(0, 242, 255, 0.2);
}

.profile-comment-form .submit-btn {
    align-self: flex-end;
    padding: 8px 20px;
    border-radius: 6px;
    cursor: pointer;
    background: var(--neon-accent, #00f2ff);
    color: #000;
    border: none;
    font-weight: bold;
    transition: all 0.3s ease;
}

.profile-comment-form .submit-btn:hover {
    box-shadow: 0 0 15px var(--neon-accent, #00f2ff);
    transform: translateY(-2px);
}

/* Список комментариев */
#profile-comments-list {
    padding: 0; /* Убираем отступы у контейнера */
}

.profile-comment-item {
    display: flex;
    align-items: flex-start;
    padding: 15px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    position: relative; /* Для позиционирования кнопки удаления */
}

.profile-comment-item:last-child {
    border-bottom: none;
}

.comment-author-avatar {
    margin-right: 15px;
}

.comment-author-avatar img {
    border-radius: 50%;
    width: 40px;
    height: 40px;
}

.comment-details {
    flex-grow: 1;
}

.comment-meta {
    display: flex;
    align-items: center;
    margin-bottom: 5px;
}

.comment-author-name {
    font-weight: bold;
    color: #fff;
    text-decoration: none;
    margin-right: 10px;
}

.comment-author-name:hover {
    text-decoration: underline;
}

.comment-date {
    font-size: 0.8em;
    color: rgba(255, 255, 255, 0.5);
}

.comment-content p {
    margin: 0;
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.5;
    word-break: break-word;
}

.delete-comment-btn {
    position: absolute;
    top: 10px;
    right: 15px;
    color: rgba(255, 255, 255, 0.4);
    font-size: 20px;
    font-weight: bold;
    text-decoration: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.profile-comment-item:hover .delete-comment-btn {
    opacity: 1;
}

.delete-comment-btn:hover {
    color: #ff4d4d;
}

.loading-placeholder {
    padding: 20px;
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
}

/* Дополнительные мобильные медиа-запросы */
@media (max-width: 768px) {
    /* Общие мобильные улучшения */
    .container {
        padding: 15px;
    }
    
    .profile-header {
        padding: 20px 15px;
        flex-direction: column;
        align-items: flex-start;
    }
    
    .header-left, .header-right {
        width: 100%;
        justify-content: space-between;
    }
    
    .header-right {
        align-items: flex-start;
        margin-top: 15px;
    }
    
    .avatar-container {
        width: 90px;
        height: 90px;
    }
    
    .username-row h1 {
        font-size: 1.8rem;
    }
    
    .level-badge {
        margin-top: 10px;
    }
    
    .level-circle {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .exp-container {
        width: 100%;
        max-width: 200px;
    }
    
    .hero-banner {
        height: 200px;
    }
    
    .content-columns {
        grid-template-columns: 1fr;
    }
    
    .block-header {
        padding: 8px 15px;
    }
    
    .block-header h2, .block-header h3 {
        font-size: 1rem;
    }
    
    .scroll-container {
        max-height: 300px;
        padding: 10px;
    }
    
    .comment-card {
        padding: 12px;
        gap: 10px;
    }
    
    .comment-avatar {
        width: 35px;
        height: 35px;
    }
    
    .post-input-area {
        padding: 10px;
    }
    
    #post-content {
        height: 60px;
    }
    
    .badges-row {
        overflow-x: auto;
        padding: 10px;
        -webkit-overflow-scrolling: touch;
    }
    
    .badge-item {
        flex: 0 0 auto;
    }
    
    .stats-block, .menu-block {
        padding: 15px;
    }
    
    .stats-title-main, .stats-subtitle-main {
        font-size: 1.1rem;
    }
    
    .friend-item {
        padding: 10px 15px;
        gap: 10px;
    }
    
    .friend-avatar {
        width: 32px;
        height: 32px;
    }
    
    .friend-lvl {
        width: 26px;
        height: 26px;
        font-size: 0.65rem;
    }
}

@media (max-width: 480px) {
    /* Адаптация для самых маленьких экранов */
    body {
        font-size: 14px;
    }
    
    .container {
        padding: 10px;
    }
    
    .profile-header {
        padding: 15px 10px;
    }
    
    .avatar-container {
        width: 75px;
        height: 75px;
        border-width: 2px;
    }
    
    .username-row h1 {
        font-size: 1.5rem;
    }
    
    .location {
        font-size: 0.9rem;
    }
    
    .level-circle {
        width: 35px;
        height: 35px;
        font-size: 0.85rem;
    }
    
    .level-label {
        font-size: 0.9rem;
    }
    
    .hero-banner {
        height: 150px;
    }
    
    .block-header h2, .block-header h3 {
        font-size: 0.9rem;
    }
    
    .comment-card {
        flex-direction: column;
    }
    
    .comment-top {
        flex-direction: column;
        align-items: flex-start;
        gap: 3px;
    }
    
    .comment-author {
        font-size: 0.95rem;
    }
    
    .comment-time {
        font-size: 0.75rem;
    }
    
    .comment-text {
        font-size: 0.9rem;
    }
    
    #post-content {
        height: 50px;
        font-size: 0.9rem;
    }
    
    .submit-btn {
        padding: 6px 15px;
        font-size: 0.9rem;
    }
    
    .menu-list li {
        padding: 10px 15px;
        font-size: 0.9rem;
    }
    
    .menu-icon {
        width: 20px;
        margin-right: 10px;
    }
    
    .stat-list li {
        font-size: 0.85rem;
    }
    
    .friend-name {
        font-size: 0.9rem;
    }
    
    .friend-status {
        font-size: 0.75rem;
    }
    
    /* Адаптация формы комментариев */
    .profile-comment-form textarea {
        min-height: 60px;
        font-size: 0.9rem;
    }
    
    .profile-comment-form .submit-btn {
        padding: 6px 12px;
        font-size: 0.85rem;
    }
    
    /* Адаптация пагинации */
    .pagination-links .page-numbers a,
    .pagination-links .page-numbers span {
        padding: 6px 10px;
        font-size: 0.85rem;
    }
    
    /* Адаптация ссылок профиля */
    .profile-link-item {
        flex-direction: column;
        gap: 8px;
        padding: 10px;
        font-size: 0.9rem;
    }
    
    .profile-link-item svg {
        width: 24px;
        height: 24px;
    }
}

/* Улучшения для мобильного ввода */
input, textarea, select, button {
    -webkit-tap-highlight-color: transparent;
    -webkit-touch-callout: none;
}

/* Фикс для iOS при повороте */
@media (orientation: landscape) {
    .hero-banner {
        height: 180px;
    }
    
    .scroll-container {
        max-height: 250px;
    }
}

/* Улучшенная адаптация для маленьких экранов */
@media (max-height: 600px) {
    .scroll-container {
        max-height: 200px;
    }
    
    .content-columns {
        grid-template-rows: auto auto;
    }
}

/* Дополнительные улучшения для мобильных */
.glass {
    border-radius: 12px;
}

.edit-profile-btn, .submit-btn, .load-more-btn {
    min-height: 40px;
}

/* Фикс для длинных слов в комментариях */
.comment-text {
    overflow-wrap: break-word;
    word-wrap: break-word;
    hyphens: auto;
}

/* Улучшенная адаптация для клавиатуры на мобильных */
@media (hover: none) {
    .post-input-area, .profile-comment-form {
        padding-bottom: max(20px, env(safe-area-inset-bottom));
    }
}

/* Адаптация для скролла в меню */
.menu-list {
    max-height: 300px;
    overflow-y: auto;
}

/* Добавляем плавное появление элементов при скролле на мобильных */
@media (max-width: 768px) {
    .newsfeed-block, .status-block, .badges-block, .menu-block, .stats-block, .friends-block {
        animation: fadeIn 0.3s ease-out;
    }
    
    @keyframes fadeIn {
        from { opacity: 0; transform: translateY(10px); }
        to { opacity: 1; transform: translateY(0); }
    }
}.stat-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    padding: 9px 1px;
    text-align: center;
    transition: transform 0.2s, background 0.2s;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 50px;
}
.stats-grid-container {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 2px;
    padding: 10px 0;
    margin-left: 10px;
    margin-top: -21px;
    margin-bottom: -5px;
    margin-right: 10px;
}
.stats-header {
    margin-bottom: 15px; /* Отступ снизу от заголовка до содержимого */
    padding-bottom: 8px; /* Отступ внутрь снизу */
    border-bottom: 1px solid rgba(255, 255, 255, 0.1); /* Тонкая светлая граница снизу */
    background: linear-gradient(to right, rgba(255, 255, 255, 0.05), transparent); /* Легкий градиент фона */
    border-radius: 8px 8px 0 0; /* Закругление только верхних углов */
}

.stats-header h2 {
    margin: 0; /* Убираем стандартные отступы у заголовка */
    padding: 0; /* Убираем внутренние отступы у заголовка */
    font-size: 1.2em; /* Размер шрифта */
    font-weight: 600; /* Жирность шрифта */
    color: #ffffff; /* Цвет текста заголовка */
    letter-spacing: 0.5px; /* Расстояние между буквами */
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3); /* Легкая тень для глубины */
}
.stat-card-icon {
    flex-shrink: 0;
    margin-right: 15px;
}

}.stat-card-icon img {
    width: 60px;
    height: 60px;
    object-fit: contain;
}/* Адаптация статистических карточек для мобильных устройств */
@media (max-width: 768px) {
    .stats-grid-container {
        grid-template-columns: repeat(3, 1fr);
        gap: 4px;
        margin-left: 5px;
        margin-right: 5px;
        margin-top: -15px;
        padding: 8px 0;
    }
    
    .stat-card {
        min-height: 45px;
        padding: 7px 0;
        border-radius: 4px;
    }
    
    .stat-card-icon img {
        width: 45px;
        height: 45px;
    }
    
    .stats-header {
        border-radius: 6px 6px 0 0;
        margin-bottom: 12px;
        padding: 0 10px 6px;
    }
    
    .stats-header h2 {
        font-size: 1.1em;
    }
}

@media (max-width: 480px) {
    .stats-grid-container {
        grid-template-columns: repeat(2, 1fr);
        gap: 6px;
        margin-top: -10px;
        padding: 6px 0;
    }
    
    .stat-card {
        min-height: 40px;
        padding: 5px 0;
        border-width: 0.8px;
        border-radius: 3px;
    }
    
    .stat-card-icon {
        margin-right: 8px;
    }
    
    .stat-card-icon img {
        width: 35px;
        height: 35px;
    }
    
    .stats-header {
        border-radius: 4px 4px 0 0;
        margin-bottom: 10px;
        padding: 0 8px 5px;
    }
    
    .stats-header h2 {
        font-size: 1em;
        letter-spacing: 0.3px;
    }
    
    /* Адаптация для очень маленьких экранов */
    .stat-card .value {
        font-size: 0.95em;
    }
    
    .stat-card .label {
        font-size: 0.75em;
    }
}

/* Дополнительные улучшения для мобильных */
@media (max-width: 600px) {
    .stats-grid-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 5px;
        margin-left: 0;
        margin-right: 0;
    }
    
    /* Скрываем горизонтальный скроллбар на iOS */
    .stats-grid-container::-webkit-scrollbar {
        display: none;
    }
    
    .stat-card {
        width: calc(100% - 4px); /* Учитываем gap между карточками */
    }
}

/* Фикс для вертикальной ориентации на мобильных */
@media (max-width: 768px) and (orientation: portrait) {
    .stats-grid-container {
        margin-top: -12px;
    }
}

/* Адаптация для маленьких экранов с высоким разрешением */
@media (max-height: 600px) and (max-width: 480px) {
    .stats-grid-container {
        grid-template-columns: 1fr 1fr;
        gap: 3px;
        margin-top: -5px;
    }
    
    .stat-card {
        min-height: 35px;
        padding: 4px 0;
    }
    
    .stat-card-icon img {
        width: 30px;
        height: 30px;
    }
}

/* Улучшенная адаптация для карточек статистики */
.stat-card {
    /* Добавляем сглаженные углы для мобильных */
    border-radius: 4px;
    
    /* Увеличиваем область нажатия */
    touch-action: manipulation;
    
    /* Оптимизируем отображение текста */
    font-feature-settings: "liga" 1, "clig" 1;
}

/* Адаптация для длинных меток */
.stat-card .label {
    white-space: normal;
    word-break: break-word;
    line-height: 1.2;
    max-height: 36px;
    overflow: hidden;
}

/* Плавное появление карточек при загрузке */
@media (max-width: 768px) {
    .stat-card {
        animation: fadeInUp 0.3s ease-out forwards;
        opacity: 0;
        transform: translateY(10px);
    }
    
    .stat-card:nth-child(1) { animation-delay: 0.1s; }
    .stat-card:nth-child(2) { animation-delay: 0.15s; }
    .stat-card:nth-child(3) { animation-delay: 0.2s; }
    .stat-card:nth-child(4) { animation-delay: 0.25s; }
    .stat-card:nth-child(5) { animation-delay: 0.3s; }
    .stat-card:nth-child(6) { animation-delay: 0.35s; }
    
    @keyframes fadeInUp {
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
}