@font-face {
  font-family: 'HSESans';
  src: url('fonts/HSESans-Regular.woff2') format('woff2'),
       url('fonts/HSESans-Regular.woff') format('woff');
  font-weight: normal;
  font-style: normal;
}

:root {
  --bg-color: #e9e9e9;
  --text-color: #333;
  --header-bg: #262626;
  --header-color: #fff;
  --card-bg: #fff;
  --card-shadow: rgba(0, 0, 0, 0.1);
  --card-text: #444;
  --card-role: #666;
  --modal-bg: #fff;
  --modal-text: #333;
  --modal-detail: #444;
  --footer-bg: #fafafa;
  --footer-text: #666;
  --sidebar-bg: #333;
  --sidebar-text: #fff;
  --sidebar-hover: #444;
  --sidebar-active: #555;
  --link-color: #0066cc;
  --preloader-bg: #fff;
  --gradient-light: linear-gradient(45deg, 
    #d0d0d0, #e0e0e0, #f0f0f0, #e5e5e5, 
    #d5d5d5, #c9c9c9, #dbdbdb, #e8e8e8, #d0d0d0);
  --gradient-dark: linear-gradient(45deg, 
    #1a1a1a, #2a2a2a, #333333, #3d3d3d, 
    #292929, #1e1e1e, #262626, #303030, #1a1a1a);
  --glow-light: rgba(150, 150, 150, 0.5);
  --glow-dark: rgba(80, 80, 80, 0.6);
  --card-gradient: var(--gradient-light);
  --card-glow: var(--glow-light);
}

[data-theme="dark"] {
  --bg-color: #121212;
  --text-color: #e0e0e0;
  --header-bg: #1e1e1e;
  --header-color: #f5f5f5;
  --card-bg: #1e1e1e;
  --card-shadow: rgba(255, 255, 255, 0.05);
  --card-text: #cccccc;
  --card-role: #aaaaaa;
  --modal-bg: #2a2a2a;
  --modal-text: #e0e0e0;
  --modal-detail: #b0b0b0;
  --footer-bg: #1a1a1a;
  --footer-text: #999999;
  --sidebar-bg: #1a1a1a;
  --sidebar-text: #e0e0e0;
  --sidebar-hover: #333333;
  --sidebar-active: #444444;
  --link-color: #4d9aff;
  --preloader-bg: #121212;
  --card-gradient: var(--gradient-dark);
  --card-glow: var(--glow-dark);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'HSESans', sans-serif;
  background-color: var(--bg-color);
  color: var(--text-color);
  line-height: 1.6;
  transition: background-color 0.3s ease, color 0.3s ease;
}


header {
  font-family: 'HSESans';
  background-color: var(--header-bg);
  color: var(--header-color);
  text-align: center;
  padding: 15px 0;
  margin-bottom: 40px;
  transition: background-color 0.3s ease, color 0.3s ease;
}

header h1 {
  font-size: 2rem;
}


.team-section {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

/* Переключатель темы */
.theme-switch-wrapper {
  position: absolute;
  top: 15px;
  right: 15px;
  z-index: 999;
}

.theme-switch {
  display: inline-block;
  height: 28px;
  position: relative;
  width: 56px;
}

.theme-switch input {
  display:none;
}

.slider {
  background-color: #ccc;
  bottom: 0;
  cursor: pointer;
  left: 0;
  position: absolute;
  right: 0;
  top: 0;
  transition: .4s;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 4px;
}

.slider:before {
  background-color: #fff;
  bottom: 3px;
  content: "";
  height: 22px;
  left: 4px;
  position: absolute;
  transition: .4s;
  width: 22px;
  z-index: 1;
}

input:checked + .slider {
  background-color: #2196F3;
}

input:checked + .slider:before {
  transform: translateX(26px);
}

.slider.round {
  border-radius: 34px;
}

.slider.round:before {
  border-radius: 50%;
}

.sun-icon, .moon-icon {
  font-size: 14px;
  z-index: 0;
}

.team-member {
  display: flex;
  align-items: center;
  background-color: var(--card-bg);
  margin-bottom: 40px;
  padding: 20px;
  border-radius: 10px;
  opacity: 0;
  transform: translateX(0);
  transition: all 0.4s ease;
  box-shadow: 0 5px 15px var(--card-shadow);
  cursor: pointer;
  position: relative;
  border: 2px solid transparent;
  overflow: hidden;
}

.team-member:hover {
  box-shadow: 0 0 25px 5px var(--card-glow);
  transform: translateY(-5px);
}

.team-member::before {
  content: "";
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: var(--card-gradient);
  background-size: 400%;
  z-index: -1;
  border-radius: 12px;
  opacity: 0;
  transition: opacity 0.5s;
}

.team-member:hover::before {
  opacity: 1;
  animation: animate-border 3s linear infinite;
}

@keyframes animate-border {
  0% {
    background-position: 0 0;
  }
  50% {
    background-position: 300% 0;
  }
  100% {
    background-position: 0 0;
  }
}


.team-member img {
  width: 150px;
  height: 150px;
  object-fit: cover;
  border-radius: 50%;
  margin-right: 20px;
  border: 5px solid var(--card-bg);
  box-shadow: 0 0 0 5px var(--header-bg);
  transition: border-color 0.3s ease;
}

.team-member:last-child {
  margin-bottom: 100px;
}

.member-info {
  flex: 1;
}

.member-name {
  font-size: 1.4rem;
  margin-bottom: 8px;
  font-weight: bold;
  color: var(--modal-text);
  transition: color 0.3s ease;
}

.member-role {
  font-size: 1rem;
  color: var(--card-role);
  margin-bottom: 12px;
  transition: color 0.3s ease;
}

.member-description {
  font-size: 0.95rem;
  color: var(--card-text);
  transition: color 0.3s ease;
}

.slide-in-left {
  transform: translateX(-50px);
}

.slide-in-right {
  transform: translateX(50px);
}

.visible {
  opacity: 1;
  transform: translateX(0);
}

:root {
  --scroll-indicator-color: #4285f4;
}

[data-theme="dark"] {
  --scroll-indicator-color: #8ab4f8;
}

.scroll-progress-indicator {
  position: fixed;
  top: 0;
  left: 0;
  height: 4px;
  background: var(--scroll-indicator-color);
  width: 0%;
  z-index: 9999;
  transition: width 0.2s, opacity 0.6s;
  opacity: 0;
}

.scroll-progress-indicator.visible {
  opacity: 1;
}

@media (max-width: 768px) {
  header h1 {
    font-size: 1.5rem;
  }
  .team-member {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .team-member img {
    margin-right: 0;
    margin-bottom: 15px;
    width: 120px;
    height: 120px;
  }
  .member-name {
    font-size: 1.2rem;
  }
  .member-role {
    font-size: 0.9rem;
  }
  .member-description {
    font-size: 0.85rem;
  }
  
  .theme-switch-wrapper {
    top: 25px;
    right: 15px;
  }
}

.hamburger {
  position: absolute;
  top: 15px;
  left: 15px;
  font-size: 1.8rem;
  color: var(--header-color);
  cursor: pointer;
  z-index: 999;
  transition: color 0.3s ease;
}

.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: 220px;
  height: 100vh;
  background-color: var(--sidebar-bg);
  transform: translateX(-220px);
  transition: transform 0.3s ease, background-color 0.3s ease;
  z-index: 998;
  display: flex;
  flex-direction: column;
  padding-top: 60px;
}

.sidebar.open {
  transform: translateX(0);
}

.sidebar .nav-link {
  color: var(--sidebar-text);
  text-decoration: none;
  padding: 15px 20px;
  font-size: 1rem;
  border-bottom: 1px solid var(--sidebar-hover);
  transition: background-color 0.3s ease, color 0.3s ease;
}

.sidebar .nav-link:hover {
  background-color: var(--sidebar-hover);
}

.sidebar .nav-link.active {
  background-color: var(--sidebar-active);
  font-weight: bold;
}

.about-content,
.contacts-content {
  width: 90%;
  max-width: 800px;
  margin: 0 auto;
  padding: 20px 0;
  line-height: 1.8;
}

.about-content p,
.contacts-content p {
  margin-bottom: 1em;
  transition: color 0.3s ease;
}

.contacts-content a {
  color: var(--link-color);
  transition: color 0.3s ease;
}

.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  pointer-events: none;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: opacity 0.3s ease;
  z-index: 1000;
}

.modal.open {
  opacity: 1;
  pointer-events: auto;
}

.modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0,0,0,0.4);
}

.modal-content {
  position: relative;
  z-index: 1001;
  background-color: var(--modal-bg);
  max-width: 600px;
  width: 90%;
  padding: 20px 30px;
  border-radius: 8px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.3);
  transform: translateY(-20px);
  transition: transform 0.3s ease, background-color 0.3s ease;
}

.modal.open .modal-content {
  transform: translateY(0);
}

.modal-close {
  position: absolute;
  top: 15px;
  right: 20px;
  font-size: 2rem;
  color: var(--modal-text);
  cursor: pointer;
  transition: color 0.3s ease;
}

#modal-title {
  margin-top: 0;
  margin-bottom: 0.5em;
  color: var(--modal-text);
  transition: color 0.3s ease;
}

#modal-description {
  margin-bottom: 1em;
  font-weight: bold;
  color: var(--card-role);
  transition: color 0.3s ease;
}

#modal-details {
  color: var(--modal-detail);
  line-height: 1.4;
  transition: color 0.3s ease;
}

.about-logo {
  display: block;
  margin: 0 auto 20px;
  max-width: 150px;
  height: auto;
}

.preloader {
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  height: 100vh;
  background-color: var(--preloader-bg);
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 1;
  transition: opacity 0.5s ease, background-color 0.3s ease;
}

.preloader-logo-container {
  text-align: center;
}

.preloader-logo {
  width: 150px;
  height: auto;
  max-width: 80vw;
  display: block;
  margin: 0 auto;
  animation: blink 1s infinite alternate;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.1; }
}

img {
  max-width: 100%;
  height: auto;
}

html, body {
  margin: 0;
  padding: 0;
  transition: opacity 0.5s ease;
}
main {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 1s ease, transform 1s ease;
}
main.loaded {
  opacity: 1;
  transform: translateY(0);
}

.fade-out {
  opacity: 0;
}

footer {
  flex-shrink: 0;
  text-align: center;
  padding: 8px 0;
  background-color: var(--footer-bg);
  color: var(--footer-text);
  font-size: 0.9rem;
  margin-top: 20px;
  transition: background-color 0.3s ease, color 0.3s ease;
}
#videoCont {
  display: none !important; /* Принудительно скрываем элемент */
  border: none;
}