* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* темы */
:root {

 /*----- Цвета ----------------------*/

  /* общие */
  --main-accent-color: rgb(250, 235, 215);
  --main-bg-color: rgba(255, 255, 255, 0.6);

  /* для текста */
  --text-color-base: rgb(0, 0, 0);
  --text-color-title: rgb(255, 255, 255);
  --text-color-subtitle: rgb(33, 0, 154);
  --text-color-accent: rgb(22, 179, 161);

  /* для кнопоки и подобных эллементов */
  --btn-color-accent-sub: rgb(2, 69, 146);
  --btn-color-accent: rgb(0, 119, 255);
  --btn-color-base: rgba(0, 30, 255, 0.637);
  /* текст внутри кнопок */
  --btn-color-accent-text: rgb(250, 235, 215);
  --btn-color-text: rgb(255, 255, 255);
  
  /* переменные для шрифтов */
  --font-main: 'Fira Code', monospace;
  

  /* переменные для фоновыйх изображений */
  --bg-img-1: url('../assets/img/bg/bg1.jpg');
  --bg-img-2: url('../assets/img/bg/bg1.jpg');
  --bg-img-3: url('../assets/img/bg/bg3.jpg');
    --bg-gradient: linear-gradient(135deg, #767676, #9d9d9d);

}

body.light {
  
 /*----- Цвета ----------------------*/

  /* общие */
  --main-accent-color: rgb(43, 179, 22);
  --main-bg-color: rgba(30, 34, 47, 0.8);

  /* для текста */
  --text-color-base: rgb(255, 255, 255);
  --text-color-title: rgb(255, 255, 255);
  --text-color-subtitle: rgb(0, 120, 38);
  --text-color-accent: rgb(0, 255, 225);
  
   /* для кнопоки и подобных эллементов */
  --btn-color-accent-sub: rgb(19, 96, 7);
  --btn-color-accent: rgb(43, 179, 22);
  --btn-color-base: rgb(0, 0, 0);
  --btn-color-text: rgb(255, 255, 255);
  
  /* переменные для шрифтов */
  --font-main: 'Fira Code', monospace;
  
  /* переменные для фоновыйх изображений */
  --bg-img-1: url('../assets/img/bg/bg1.jpg');
  --bg-img-2: url('../assets/img/bg/bg2.jpg');
  --bg-img-3: url('../assets/img/bg/bg3.jpg');
    --bg-gradient: linear-gradient(135deg, #414141, #515151);

  
}


/* запасные на будущее */
body.dark {

  /*----- Цвета ----------------------*/

  /* общие */
  --main-accent-color: rgb(0, 119, 255); /* тот же акцент, чтобы сохранить фирменный стиль */
  --main-bg-color: rgba(20, 24, 34, 0.95); /* глубокий тёмный фон с лёгкой прозрачностью */

  /* для текста */
  --text-color-base: rgb(230, 230, 230); /* светлый текст для читаемости */
  --text-color-title: rgb(255, 255, 255); /* белый заголовок */
  --text-color-subtitle: rgb(0, 153, 255); /* яркий голубой — читаемый и акцентный */
  --text-color-accent: rgb(22, 179, 161); /* сохраняем акцентный бирюзовый */

  /* для кнопоки и подобных эллементов */
  --btn-color-accent-sub: rgb(0, 60, 120); /* глубокий синий для вторичных кнопок */
  --btn-color-accent: rgb(0, 119, 255); /* основной акцент */
  --btn-color-base: rgba(0, 30, 255, 0.3); /* прозрачный синий фон */
  --btn-color-text: rgb(255, 255, 255); /* белый текст на кнопках */

  /* переменные для шрифтов */
  --font-main: 'Fira Code', monospace;

  /* переменные для фоновыйх изображений */
  --bg-img-1: url('../assets/img/bg/bg1.jpg');
  --bg-img-2: url('../assets/img/bg/bg1.jpg');
  --bg-img-3: url('../assets/img/bg/bg3.jpg');
  --bg-gradient: linear-gradient(135deg, #1c1c1c, #2a2a2a); /* тёмный градиент */
}

body.ultra-light {

  /*----- Цвета ----------------------*/

  /* общие */
  --main-accent-color: rgb(0, 200, 255); /* яркий голубой акцент */
  --main-bg-color: rgba(245, 250, 255, 0.95); /* светлый фон с лёгкой прозрачностью */

  /* для текста */
  --text-color-base: rgb(20, 20, 20); /* почти чёрный — для читаемости на светлом фоне */
  --text-color-title: rgb(0, 80, 160); /* насыщенный синий — для заголовков */
  --text-color-subtitle: rgb(0, 150, 120); /* мягкий бирюзовый — для подзаголовков */
  --text-color-accent: rgb(255, 0, 120); /* яркий розовый — для акцентов */

  /* для кнопок и подобных элементов */
  --btn-color-accent-sub: rgb(0, 100, 180); /* глубокий синий — для вторичных кнопок */
  --btn-color-accent: rgb(0, 200, 255); /* тот же акцент, что и основной */
  --btn-color-base: rgb(255, 255, 255); /* белый фон кнопки */
  --btn-color-text: rgb(0, 0, 0); /* чёрный текст на кнопке */

  /* переменные для шрифтов */
  --font-main: 'Fira Code', monospace;

  /* переменные для фоновых изображений */
  --bg-img-1: url('../assets/img/bg/bg1.jpg');
  --bg-img-2: url('../assets/img/bg/bg2.jpg');
  --bg-img-3: url('../assets/img/bg/bg3.jpg');
  --bg-gradient: linear-gradient(135deg, #d0f0ff, #f0faff); /* светлый градиент */
}


@media (prefers-color-scheme: light) {
  body {
    --main-bg-color: rgba(255, 255, 255, 0.6);
    --text-color-base: rgb(0, 0, 0);
  }
}

body {
background: var(--bg-gradient), var(--bg-img-2);
background-blend-mode: overlay;
background-size: cover;              
background-position: center center;  
background-repeat: no-repeat;        
background-attachment: fixed;        
font-family: var(--font-main);
line-height: 1.6;
padding: 2rem;
}

.btn-scroll-toggle {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 48px;
  height: 48px;
  background-color: var(--btn-color-accent);
  color: #fff;
  border: none;
  border-radius: 50%;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  cursor: pointer;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}

.btn-scroll-toggle:hover {
  background-color: var(--btn-color-accent-sub);
}

/* контент  */

header {
  text-align: center;
  margin-bottom: 3rem;
}

.slogan {
  font-size: 1.3rem;
  color: var(--text-color-base);
  letter-spacing: 1px;
  margin: 1rem auto;
  max-width: 40%;
  background: rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  padding: 1rem;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

.slogan h1 {
  font-size: 1.6rem;
  color: var(--text-color-title);
}

.slogan p {
  color: var(--text-color-title);
  font-size: 1rem;
  margin-top: 0.5rem;
}

nav {
  margin: 1rem auto;
  max-width: 600px;
  background: rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  padding: 1rem;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

nav a {
  color: var(--btn-color-text);
  text-decoration: none;
  margin: 0 1rem;
  transition: color 0.3s ease;
}

nav a:hover {
  color: var(--btn-color-accent);
}

main {
  max-width: 800px;
  margin: 0 auto;
}

/* переключатель темы */
.themeToggle {
  position: fixed;
  top: 1rem;
  right: 1rem;
  z-index: 1000;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: linear-gradient(135deg, var(--btn-color-accent), var(--btn-color-accent-sub));
  color: var(--btn-color-text);
  border: none;
  border-radius: 50%;
  padding: 0.6rem 1rem;
  font-size: 1rem;
  font-family: var(--font-main);
  cursor: pointer;

  box-shadow: 0 0 12px var(--main-accent-color);
  backdrop-filter: blur(6px);
  transition: transform 0.2s ease;
}

.themeIcon, .themeLabel {
  transition: transform 0.4s ease, opacity 0.4s ease;
}

/* Когда скрываем  */
.themeToggle.hide .themeIcon,
.themeToggle.hide .themeLabel {
  transform: rotate(360deg);
  opacity: 0;
}


/* Оформление карточек постов */
article {
  background: var(--main-bg-color);
  padding: 2rem;
  border-left: 4px solid var(--main-accent-color);
  border-radius: 16px;
  margin-bottom: 2rem;
  transition: transform 0.2s ease;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeIn 0.6s ease-out forwards;
}

article h2 {
  color: var(--text-color-subtitle);
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

article p {
  color: var(--text-color-base);
}


article small {
  color: var(--text-color-base);
}

article .link-for-post {
    display: inline-block;
    margin-top: 1rem;
    color: var(--text-color-base);
    text-decoration: none;
    font-weight: bold;
    background: var(--btn-color-accent);
    padding: 2px 10px;
    border-radius: 20px 10px;
}

.link-for-post:hover {
  color: var(--btn-color-accent-text);
  transition: color 0.3s ease;
}

.link-for-post::after {
  content: " 🔗";
  font-size: 0.9em;
}




/* =============================
footer
=============================== */
.site-footer {
  text-align: center;
  margin-top: 6rem;
  padding: 2rem 1rem;
  font-size: 0.9rem;
  color: var(--text-color-base);
  background: rgba(165, 165, 165, 0.6);
  border-radius: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(4px);
  transition: background 0.3s ease;
}

body.light .site-footer {
  background: rgba(255, 255, 255, 0.4);
  border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.site-footer a {
  color: var(--main-accent-color);
  text-decoration: none;
  font-weight: 500;
}

.site-footer a:hover {
  text-decoration: underline;
}

/* ========================== */
@keyframes fadeIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
/* медиа в постах */
.mediaWrapper {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 8px;
  margin-top: 10px;
}

.mediaThumb {
  width: 100%;
  height: auto;
  border-radius: 6px;
  cursor: pointer;

}

.mediaWrapper:has(.mediaThumb:only-child) {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 400px; /* ограничиваем высоту контейнера */
}

.mediaWrapper:has(.mediaThumb:only-child) .mediaThumb {
  max-height: 100%;
  object-fit: cover;
}


.mediaModal {
  display: none;
  position: fixed;
  z-index: 999;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  justify-content: center;
  align-items: center;
}

.mediaModal img {
  max-width: 90%;
  max-height: 90%;
  border-radius: 8px;
  box-shadow: 0 0 20px rgba(0,0,0,0.5);
}


/* блок сервисов */
.fixed-box-services {
  position: fixed;
  top: 50%;
  right: -175px;
  transform: translateY(-50%);
  width: 220px;
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 12px 0 0 12px;
  padding: 1rem 1rem 1rem 0.5rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  z-index: 1050;
  transition: right 0.3s ease;
}

.fixed-box-services a.button {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--btn-color-accent);
  color: var(--btn-color-text);
  font-family: var(--font-main);
  font-size: 0.95rem;
  font-weight: bold;
  text-decoration: none;
  padding: 0.6rem 1rem;
  border-radius: 8px;
  transition: background 0.3s ease, transform 0.2s ease;
  box-shadow: 0 0 10px var(--main-accent-color);
}

.fixed-box-services a.button:hover {
  transform: translateX(-150px);
}


.aside-toggle {
  position: fixed;
  top: 20px;
  left: 20px;
  z-index: 1100;
  background: var(--btn-color-accent);
  color: var(--btn-color-text);
  border: none;
  padding: 0.6em 1em;
  font-family: var(--font-main);
  font-size: 0.9em;
  border-radius: 6px;
  cursor: pointer;
  box-shadow: 0 0 12px var(--btn-color-accent-sub);
  transition: background 0.2s ease;
}

.aside-toggle:hover {
  background: var(--btn-color-accent-sub);
}

#radioAside {
  position: fixed;
  top: 0;
  left: -300px;
  width: 280px;
  height: 100vh;
  background: rgba(20, 20, 20, 0.95);
  border-right: 1px solid var(--main-accent-color);
  padding: 1.2em;
  font-family: var(--font-main);
  color: var(--fg);
  z-index: 1050;
  overflow-y: auto;
  box-sizing: border-box;
  transition: left 0.3s ease;
  scrollbar-width: thin;
  scrollbar-color: var(--main-accent-color) rgba(30, 30, 30, 0.6);
}

#radioAside.open {
  padding-top: 5rem;
  left: 0;
}

#radioAside::-webkit-scrollbar {
  width: 8px;
}

#radioAside::-webkit-scrollbar-track {
  background: rgba(30, 30, 30, 0.6);
  border-radius: 4px;
}

#radioAside::-webkit-scrollbar-thumb {
  background: var(--main-accent-color);
  border-radius: 4px;
  transition: background 0.2s ease;
}

#radioAside::-webkit-scrollbar-thumb:hover {
  background: #00bfa5;
}

#radioAside h1 {
  font-size: 1em;
  color: var(--main-accent-color);
  margin-bottom: 1em;
  line-height: 1.4;
  font-weight: 500;
}

.radio-list {
  display: flex;
  flex-direction: column;
  gap: 0.4em;
}

.radio-btn {
  background: transparent;
  border: 1px dashed var(--main-accent-color);
  color: var(--main-accent-color);
  padding: 0.4em 0.6em;
  font-size: 0.85em;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.2s ease;
  text-align: left;
}

.radio-btn:hover {
  background: var(--main-accent-color);
  color: #000;
}

#radioStatus {
  margin-top: 0.8em;
  font-size: 0.85em;
  opacity: 0.7;
  text-align: center;
}

.volume-control {
  display: flex;
  flex-direction: column;
  gap: 0.3em;
  margin-bottom: 1em;
  font-size: 0.85em;
  color: var(--accemain-accent-colornt);
}

.volume-control label {
  opacity: 0.8;
}

#volumeSlider {
  width: 100%;
  height: 4px;
  border-radius: 2px;
  outline: none;
}

#volumeSlider::-webkit-slider-thumb {
  width: 12px;
  height: 12px;
  background: var(--main-accent-color);
  border-radius: 50%;
  cursor: pointer;
}

#volumeSlider::-moz-range-thumb {
  width: 12px;
  height: 12px;
  background: var(--main-accent-color);
  border: none;
  border-radius: 50%;
  cursor: pointer;
}




/* Адаптив для мобильных  */

/* ------------ 1024px -------------------------------------------------------- */

@media (max-width: 1024px) {
  /* пока нет стилей — можно добавить позже */
}

/* ------------ 768px -------------------------------------------------------- */

@media (max-width: 768px) {
  .fixed-box-services {
  display: none;
  }

  body {
    padding: 1rem;
  }

  .slogan h1 { font-size: 2rem; }
  .slogan p { font-size: 0.9rem; }

  nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
  }

  nav a { margin: 0.5rem 0; }
  main { padding: 0 1rem; }
  article { padding: 1.5rem; }
  article h2 { font-size: 1.3rem; }
  article p { font-size: 0.95rem; }

  footer {
    font-size: 0.8rem;
    padding: 1rem;
  }


  #radioAside,
  .aside-toggle {
    display: none;
  }
}

/* ------------ 480px -------------------------------------------------------- */

@media (max-width: 480px) {
  .themeToggle {
    top: auto;
    bottom: 1rem;
    right: 1rem;
    font-size: 0.9rem;
    padding: 0.5rem 0.8rem;
  }

  .btn-scroll-toggle {
    top: auto;
    bottom: 4rem;
    right: 1rem;
    font-size: 0.9rem;
    padding: 0.5rem 0.8rem;
  }

  .slogan {
    max-width: 100%;
  }

  .slogan h1 { font-size: 1.6rem; }
  .slogan p { font-size: 0.8rem; }

  article {
    padding: 1rem;
  }

  article h2 { font-size: 1.1rem; }
  article p { font-size: 0.9rem; }
  nav a { font-size: 0.9rem; }
  footer { font-size: 0.75rem; }
}