* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Герой секция с улучшенным градиентом и анимацией */
.hero {
    height: 100vh;
    background: linear-gradient(-45deg, #667eea, #764ba2, #f093fb, #f5576c);
    background-size: 400% 400%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    position: relative;
    animation: gradientShift 15s ease infinite;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 1;
}

.hero-content {
    z-index: 2;
    position: relative;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    animation: fadeInUp 1s ease-out;
}

.hero-subtitle {
    font-size: 1.5rem;
    font-weight: 300;
    opacity: 0.9;
    animation: fadeInUp 1s ease-out 0.3s both;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 50px;
    border: 2px solid white;
    border-radius: 15px;
    z-index: 2;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.scroll-indicator:hover {
    transform: translateX(-50%) scale(1.1);
}

.scroll-indicator::before {
    content: '';
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 12px;
    background: white;
    border-radius: 2px;
    animation: scroll 2s infinite;
}

@keyframes scroll {
    0% { transform: translateX(-50%) translateY(0); opacity: 1; }
    100% { transform: translateX(-50%) translateY(20px); opacity: 0; }
}

/* Секция "О сервере" */
.about {
    padding: 100px 0;
    background: #f8f9fa;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.about-text h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    color: #2c3e50;
}

.about-text p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #555;
}

.about-image img {
    width: 100%;
    border-radius: 15px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.about-image img:hover {
    transform: translateY(-5px);
    box-shadow: 0 25px 50px rgba(0,0,0,0.15);
}

/* Фотография недели */
.photo-week {
    padding: 100px 0;
    background: white;
}

.photo-week h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #2c3e50;
}

.photo-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.photo-image img {
    width: 100%;
    border-radius: 15px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.photo-image img:hover {
    transform: scale(1.02);
}

.photo-info h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: #2c3e50;
}

.photo-info p {
    font-size: 1.1rem;
    line-height: 1.7;
    color: #555;
}

/* Страны сервера */
.countries {
    padding: 100px 0;
    background: #f8f9fa;
}

.countries h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #2c3e50;
}

.countries-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.country-card {
    background: white;
    padding: 30px;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    border: 1px solid #f0f0f0;
}

.country-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
}

.country-flag {
    width: 100px;
    height: 150px;
    margin: 0 auto 1.5rem;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    border: 2px solid #e0e0e0;
}

.country-flag img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.country-card:hover .country-flag img {
    transform: scale(1.1);
}

.country-card h3 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
    color: #2c3e50;
    min-height: 3.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.country-card p {
    color: #666;
    line-height: 1.6;
    font-style: italic;
}

/* Карта мира с лупой */
.world-map {
    padding: 100px 0;
    background: white;
}

.world-map h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #2c3e50;
}

.map-container {
    position: relative;
    width: 100%;
    height: 600px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 25px 50px rgba(0,0,0,0.15);
    cursor: grabbing;
}

.map-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.map-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.7));
    color: white;
    padding: 30px;
    text-align: center;
    pointer-events: none;
}

.map-overlay h3 {
    font-size: 1.8rem;
    margin-bottom: 10px;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.5);
}

.map-overlay p {
    font-size: 1.1rem;
    opacity: 0.9;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
}

/* Стили для лупы с исправленным позиционированием */
.magnifier {
    position: absolute;
    width: 200px;
    height: 200px;
    border: 3px solid #fff;
    border-radius: 50%;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
    box-shadow: 
        0 0 25px rgba(0,0,0,0.5),
        inset 0 0 20px rgba(255,255,255,0.1);
    z-index: 10;
    overflow: hidden;
    background-repeat: no-repeat;
    background-position: 0 0;
}

.magnifier::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 180px;
    height: 180px;
    border: 2px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    z-index: 2;
}

.magnifier::after {
    content: '🔍';
    position: absolute;
    bottom: -30px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 20px;
    opacity: 0.7;
}

.map-container:hover .magnifier {
    opacity: 1;
}

/* Адаптивность для карты с лупой */
@media (max-width: 768px) {
    .map-container {
        height: 400px;
    }
    
    .magnifier {
        width: 150px;
        height: 150px;
    }
    
    .magnifier::before {
        width: 130px;
        height: 130px;
    }
    
    .map-overlay {
        padding: 20px;
    }
    
    .map-overlay h3 {
        font-size: 1.5rem;
    }
    
    .map-overlay p {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .map-container {
        height: 300px;
        cursor: pointer;
    }
    
    .magnifier {
        width: 120px;
        height: 120px;
    }
    
    .magnifier::before {
        width: 100px;
        height: 100px;
    }
    
    .world-map {
        padding: 60px 0;
    }
    
    /* На мобильных отключаем лупу */
    @media (hover: none) {
        .map-container {
            cursor: default;
        }
        .magnifier {
            display: none;
        }
    }
}

.map-controls {
    text-align: center;
    margin-top: 15px;
}

.map-controls button {
    background: #667eea;
    color: white;
    border: none;
    padding: 10px 20px;
    margin: 0 5px;
    border-radius: 5px;
    font-size: 18px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.map-controls button:hover {
    background: #4752c4;
}

/* Секция присоединения */
.join {
    padding: 100px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    text-align: center;
    color: white;
}

.join h2 {
    font-size: 2.5rem;
    margin-bottom: 3rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.join-buttons {
    display: flex;
    gap: 30px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    display: inline-block;
    padding: 18px 45px;
    border-radius: 50px;
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.btn:hover::before {
    left: 100%;
}

.discord-btn {
    background: #5865F2;
    color: white;
    box-shadow: 0 5px 15px rgba(88, 101, 242, 0.4);
}

.discord-btn:hover {
    background: #4752c4;
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(88, 101, 242, 0.6);
}

.mods-btn {
    background: #34A853;
    color: white;
    box-shadow: 0 5px 15px rgba(52, 168, 83, 0.4);
}

.mods-btn:hover {
    background: #2e8b47;
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(52, 168, 83, 0.6);
}

/* Анимации появления при скролле */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Адаптивность */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
    
    .about-content,
    .photo-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .join-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .btn {
        width: 250px;
        text-align: center;
    }
    
    .countries-grid {
        grid-template-columns: 1fr;
    }
    
    .country-card h3 {
        min-height: auto;
    }
    
    .map-overlay {
        padding: 25px 20px 20px;
    }
    
    .map-overlay h3 {
        font-size: 1.5rem;
    }
    
    .map-overlay p {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .about, .photo-week, .countries, .world-map, .join {
        padding: 60px 0;
    }
    
    h2 {
        font-size: 2rem !important;
    }
    
    .map-overlay {
        position: relative;
        background: #f8f9fa;
        color: #333;
        padding: 20px;
    }
    
    .map-overlay h3 {
        text-shadow: none;
    }
    
    .map-overlay p {
        text-shadow: none;
    }
}

/* Добавьте это в самый конец вашего styles.css */
html {
    scroll-behavior: smooth;
}

body {
    overflow-x: hidden;
}

/* Убедимся, что все transitions работают корректно */
.about-content,
.photo-content,
.country-card,
.world-map {
    will-change: transform, opacity;
}