 

@media screen and (max-width: 768px) {
    
    .history-item img {   max-width: 200px!important;}
    .site-nav a {    padding: 0.5rem 0.4rem!important; }
    .header h1 {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 0.25rem;
    }
    .external-link-icon {
        position: static;
        transform: none;
    }

    .clicks-counter {
        margin-left: 0;
        font-size: 1rem;
        transform: none;
    }
 .page-header-panel {
        flex-direction: column;
        align-items: stretch;  
        padding: 1.5rem;
        gap: 1.5rem;
    }

    .header-main-content {
        text-align: center;
    }

    .header-stats {
       
        margin-left: auto;   
        margin-right: auto;   
        
        min-width: auto;
        max-width: 400px;  
        width: 90%;       
        
        flex-direction: row;
        justify-content: center;
        flex-wrap: wrap;
        gap: 1.5rem;
    }

    .header-title .domain-name {
        font-size: 2rem;
    }
 
}

 

.container {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.header {
    text-align: center;
    margin-bottom: 2rem;
}

.page-header-panel {
    background-color: #f8f9fa; /* Светлый фон для всего блока */
    border: 1px solid #dee2e6;
    border-radius: 16px; /* Более заметное скругление */
    padding: 2rem;
    margin-bottom: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 2rem;
}

/* Левая часть с заголовком и описанием */
.header-main-content {
    flex: 1;
    min-width: 0; /* Для правильного переноса текста в flex-контейнере */
}

.header-title {
    font-size: 1.5rem; /* Уменьшаем базовый размер для баланса */
    color: var(--text-light);
    margin: 0 0 1rem 0;
    font-weight: 500;
}

/* Ссылка с доменом и иконкой */
.domain-link-with-icon {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: var(--accent-color);
    transition: color 0.2s;
}
.domain-link-with-icon:hover {
    color: #0056b3;
}

.domain-link-with-icon .domain-name {
    font-size: 2.5rem;
    font-weight: 700;
    word-break: break-all;
}

.domain-link-with-icon svg {
    width: 24px;
    height: 24px;
}

/* Блок с описанием сайта */
.site-summary {
    font-size: 1.1em;
    line-height: 1.6;
    color: #333;
}
.site-summary p {
    margin: 0;
}

 
.header-stats {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    background-color: #ffffff;
    padding: 1rem;
    border-radius: 12px;
    border: 1px solid #e9ecef;
    min-width: 220px;  
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.stat-icon {
    background-color: #e9ecef;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #495057;
}

.stat-icon svg {
    width: 20px;
    height: 20px;
}

.stat-content {
    display: flex;
    flex-direction: column;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: #212529;
    line-height: 1.2;
}

.stat-label {
    font-size: 0.85rem;
    color: #6c757d;
}


.header .meta {
    color: var(--text-light);
}

.main-grid {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 2rem;
    align-items: flex-start;
}

.screenshot-viewer img {
    display: block;
    width: 100%;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    margin-bottom: 1.5rem;
    /* (НОВОЕ) Анимация для смены фото */
    transition: opacity 0.2s ease-in-out;
}
/* (НОВОЕ) Класс для анимации */
.screenshot-viewer img.loading {
    opacity: 0.4;
}

.history-gallery {
    overflow-x: auto;
    white-space: nowrap;
    padding-bottom: 1rem;
}

.history-item {
    display: inline-block;
    margin-right: 1rem;
    cursor: pointer;
    border: 2px solid transparent;
    border-radius: 8px;
    transition: border-color 0.2s;
    text-decoration: none;
}

.history-item:hover {
    border-color: var(--accent-color);
}

.history-item.active {
    border-color: var(--accent-color);
    box-shadow: 0 0 0 2px var(--accent-color);
}

.history-item img {
    display: block;
    max-width: 280px;
    height: auto;
    border-radius: 6px;
}

.history-item p {
    text-align: center;
    font-size: 0.8rem;
    margin: 0.5rem 0 0;
    color: var(--text-light);
}

.data-cards {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.info-grid {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.75rem 1rem;
    align-items: center;
    font-size: 0.95rem;
}

.info-grid dt {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 500;
    color: var(--text-light);
}

.info-grid dd {
    margin: 0;
    font-weight: 500;
    word-break: break-all;
}

.info-grid dd a {
    color: var(--accent-color);
    text-decoration: none;
}

.info-grid dd a:hover {
    text-decoration: underline;
}

.details-card summary {
    cursor: pointer;
    font-weight: 700;
    outline: none;
}

.details-card dl {
    margin-top: 1rem;
}

.content-headings h4 {
    margin: 1rem 0 0.5rem;
    font-size: 1rem;
}

.content-headings ul {
    margin: 0;
    padding-left: 20px;
    color: #333;
}
.views-counter {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-left: 16px;
    font-size: 0.9em;
    font-weight: 500;
    color: #4a5568;
    background-color: #edf2f7;
    padding: 4px 10px;
    border-radius: 16px;
    vertical-align: middle;
    transition: background-color 0.2s ease;
}

.views-counter:hover {
    background-color: #e2e8f0;
}

.views-counter svg {
    width: 16px;
    height: 16px;
    stroke: #718096;
}

 
.reactions-card h3 {
    margin-bottom: 1rem;
}

.reactions-container {
    display: flex;
    flex-direction: column;  
    align-items: center;   
    gap: 0.75rem;
}

 
.reaction-group {
    display: flex;
    flex-wrap: wrap;
    justify-content: center; 
    gap: 0.5rem;
    padding: 0.75rem; 
    border-radius: 12px;  
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #eee;
}

 

 
.reaction-group.positive {
    background-color: #e7f7ec; 
}

 
.reaction-group.neutral {
    background-color: #fff8e1;  
}

 
.reaction-group.negative {
    background-color: #ffebf0; 
}


.reaction-button {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background-color: #f0f2f5;
    border: 1px solid #ccd0d5;
    border-radius: 20px;
    padding: 4px 10px;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.2s ease;
}
.reaction-button:hover {
    background-color: #e4e6eb;
    border-color: #b0b3b8;
    transform: translateY(-2px);
}
.reaction-button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}
.reaction-button .emoji {
    font-size: 1.2rem;
}
.reaction-button .count {
    font-weight: 600;
    font-size: 0.9rem;
    color: #333;
}
.reaction-button.voted {
    background-color: #d0e6ff;  
    border-color: #a9cfff;
    opacity: 0.7;
    cursor: default;
    transform: none; 
}

.reaction-button.voted:hover {
    background-color: #d0e6ff;  
}

.related-domains {
    width: 100%;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e0e0e0;
}

.related-domains h3 {
    font-size: 1.5rem;
    color: #333;
    margin-bottom: 1.5rem;
    text-align: center;
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1rem;
}

.related-item {
    display: block;
    text-decoration: none;
    border-radius: 8px;
    overflow: hidden;
    background-color: #fff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
    border: 1px solid #eee;
}

.related-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0,0,0,0.1);
}

.related-item img {
    width: 100%;
    display: block;
    aspect-ratio: 19 / 13;
    object-fit: cover;
    background-color: #f0f0f0;
}

.related-item span {
    display: block;
    padding: 0.75rem;
    font-weight: 500;
    color: #333;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    background-color: #fafafa;
}
.subsequent-domains {
    width: 100%;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e0e0e0;
    text-align: center;
}

.subsequent-domains h4 {
    font-size: 1.4rem;
    color: #333;
    margin-bottom: 1.4rem;
}

.subsequent-domains .subsequent-date {
    color: #555;
    font-weight: 500;
}

.links-cloud {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    padding: 0 1rem;
}

.links-cloud a {
    display: inline-block;
    padding: 8px 16px;
    font-size: 0.9rem;
    font-weight: 500;
    color: #1a73e8;
    background-color: #e8f0fe;
    border-radius: 20px;
    text-decoration: none;
    border: 1px solid transparent;
    transition: all 0.2s ease-in-out;
}

.links-cloud a:hover {
    color: #fff;
    background-color: #1a73e8;
    border-color: #1a73e8;
    transform: scale(1.05);
    box-shadow: 0 4px 10px rgba(26, 115, 232, 0.2);
}

.clicks-counter {
    font-size: 1.2rem; /* Уменьшаем размер */
    font-weight: 500;
    color: var(--text-light); /* Светлый цвет текста */
    margin-left: -10px; /* Немного придвигаем к иконке */
    vertical-align: middle;
    transform: translateY(2px);
}

@media (max-width: 992px) {
    .main-grid {
        grid-template-columns: 1fr;
    }
    /* (НОВОЕ) ИЗМЕНЕНИЕ 3: Визуальное отделение блока "похожих сайтов" на мобильных */
    .related-domains {
        background-color: #f9f9f9; /* Легкий фон для отделения */
        
        margin-top: 2rem;
        border-radius: 12px;
        border-top: none; /* Убираем верхнюю линию, так как фон уже отделяет */
    }
    .related-grid {
        /* Делаем сетку чуть плотнее на мобильных */
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }
}