/* Общие настройки */
html { scroll-behavior: smooth; }
body { 
    font-family: 'Inter', sans-serif;
    margin: 0;
    line-height: 1.5; 
    color: #333;
    background-image: url('fon2.png'); /* Путь к картинке */
    background-size: cover;          /* Растягивает картинку на весь экран без искажений */
    background-position: center;     /* Центрирует изображение */
    background-repeat: no-repeat;    /* Запрещает размножение картинки плиткой */
    background-attachment: fixed;    /* Картинка остается на месте при скролле */
}
    /* background: linear-gradient(135deg, #e0eafc 0%, #cfdef3 100%);
    background-attachment: fixed; */

/* Навигация */
header { 
    background: rgba(255, 255, 255, 0.95); 
    backdrop-filter: blur(10px);
    position: sticky; top: 0; z-index: 1000; 
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}
nav { 
    display: flex; justify-content: space-between; align-items: center; 
    max-width: 1100px; margin: auto; padding: 10px 20px; 
}
.logo { font-size: 1.4rem; font-weight: 800; color: #007bff; text-decoration: none; letter-spacing: 1px; }
.nav-links { display: flex; align-items: center; }
.nav-links a { 
    color: #444; text-decoration: none; margin-left: 20px; 
    font-weight: 500; transition: 0.3s; font-size: 0.95rem;
}
.nav-links a:hover { color: #007bff; }

/* Контейнеры */
.container { 
    max-width: 1000px; margin: 30px auto; padding: 20px; 
    background: white; border-radius: 20px; 
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    animation: fadeIn 0.8s ease-in-out;
}
.intro-text { font-size: 1.1rem; color: #555; max-width: 800px; padding-left: 20px; }
.section-title { text-align: center; margin-bottom: 30px; font-size: 2rem; color: #222; }

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}
/* Стилизация текста в секции "О себе" */
#about h1 {
    font-size: 2rem;       /* Крупный, заметный главный заголовок */
    color: #222;             /* Темный цвет для контраста */
    margin-top: 0;           /* Убираем лишний отступ сверху */
    margin-bottom: 10px;     /* Небольшой отступ до подзаголовка */
    font-weight: 600;        /* Максимальная жирность */
    text-align: center;
}

#about h2 {
    font-size: 1.25rem;      /* Размер для подзаголовка с профессией */
    color: #007bff;          /* Фирменный синий цвет, как у вашего логотипа */
    margin-top: 0;
    margin-bottom: 20px;     /* Отступ до основного текста */
    font-weight: 600;        /* Средняя жирность */
    letter-spacing: 0.5px;   /* Легкое увеличение расстояния между буквами */
    text-align: center;
}

#about .intro-text {
    font-size: 1.1rem;
    color: #555;             /* Приятный для чтения серый цвет */
    line-height: 1.7;        /* Увеличенный межстрочный интервал для легкого чтения */
    max-width: 960px;        /* Ограничение ширины строки, чтобы текст не растягивался во всю ширину */
    text-align: justify;        /* Для больших блоков текста выравнивание по левому краю выглядит аккуратнее, чем justify */
}

/* Сетки */
.grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 
    gap: 15px; margin-top: 20px;
}
.card { 
    border-radius: 15px; overflow: hidden; border: 1px solid #f0f0f0; padding-left: 20px;
    transition: all 0.5s ease; background: #fff;
    display: flex; flex-direction: column;
}
.card:hover { transform: translateY(-8px); box-shadow: 0 20px 40px rgba(0,0,0,0.12); }
.card img { width: 100%; height: 180px; object-fit: cover; cursor: pointer; border-bottom: 1px solid #eee; }
.card-info { padding: 20px; flex-grow: 1; }
.card-info h3 { margin-top: 0; color: #007bff; }

/* Сертификаты */
.cert-card { 
    border: 1px solid #eee; 
    padding: 20px; 
    text-align: center; 
    background: #fafafa;
}
.cert-card img { 
    height: 160px; 
    object-fit: contain; 
    background: white; 
    border-radius: 8px;
    padding: 5px;
    margin-bottom: 15px;
}
.cert-card p { font-size: 0.9rem; margin-top: 10px; font-weight: 600; }

/* Контакты */
.contact-section { text-align: center; }
.social-icons { margin: 20px 0; }
.social-icons a { font-size: 2.5rem; margin: 0 20px; text-decoration: none; transition: 0.3s; display: inline-block; }
.social-icons a:hover { transform: translateY(-5px); }
.tg { color: #0088cc; }
.mail { color: #ea4335; }

.cta-button {
    display: inline-block; background: #007bff; color: white; 
    padding: 12px 35px; border-radius: 50px; text-decoration: none; 
    font-weight: 600; margin-top: 10px; transition: 0.3s;
    border: 2px solid transparent;
}
.cta-button:hover { background: #0056b3; box-shadow: 0 5px 15px rgba(0,123,255,0.3); }

/* Языковой переключатель */
.lang-switch {
    display: flex; gap: 2px; margin-left: 25px;
    background: #eee; padding: 4px; border-radius: 8px;
}
.lang-switch button {
    background: transparent; border: none; padding: 6px 12px;
    border-radius: 6px; cursor: pointer; font-weight: bold;
    font-size: 0.75rem; color: #666; transition: 0.3s;
}

/* Эффект нажатой кнопки */
body.show-en button[onclick*="'en'"],
body.show-de button[onclick*="'de'"] {
    background: #007bff; color: white; box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

/* Логика скрытия */
.lang-en, .lang-de { display: none; }
body.show-en .lang-en { display: block; }
body.show-en span.lang-en { display: inline; }
body.show-de .lang-de { display: block; }
body.show-de span.lang-de { display: inline; }

/* Адаптивность */
@media (max-width: 768px) {
    nav { flex-direction: column; gap: 15px; }
    .nav-links { flex-wrap: wrap; justify-content: center; margin-left: 0; }
    .nav-links a { margin: 5px 10px; }
    .lang-switch { margin-left: 0; margin-top: 10px; }
    .container { margin: 15px; padding: 25px; }
    .grid { grid-template-columns: 1fr; }
}
.impressum {
    border-top: 1px solid #eee;
    padding-top: 20px;
    margin-top: 40px;
    font-size: 0.8rem;
    color: #999;
}