/*==styles.css==*/
/* ===== Общие стили ===== */
html {
     font-size: clamp(11px, 0.72vw, 14px);
    box-sizing: border-box;
}

*, *::before, *::after {
    box-sizing: inherit;
}

body {
    margin: 0;
    min-width: 320px;
    overflow-x: hidden;

    font-family: "Segoe UI", Tahoma, Arial, sans-serif;
    font-size: 1rem;
    line-height: 1.6;

    color: #fff;
    background-color: #06053b;
    background-image: radial-gradient(#1f1f1f 1px, transparent 1px);
    background-size: 20px 20px;

    text-shadow:
        -1px -1px 0 #000,
         1px -1px 0 #000,
        -1px  1px 0 #000,
         1px  1px 0 #000;
}

a {
    color: #ffffff;
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: #8c8989;
}

/* Верхняя панель */
.utilitybar {
    background: #110270;
    color: #fff;
    font-size: 1.125rem;
    padding: 6px 20px;
}

.ubarinnerwrap {
    display: flex;
    justify-content: space-between; /* левые контакты и правые соцсети */
    align-items: center;
    gap: 20px;
}

.ubar-left {
    display: flex;
    align-items: center;
    gap: 20px; /* расстояние между телефоном и почтой */
}

.ubar-right {
    display: flex;
    align-items: center;
}

/* ===== Соцсети ===== */

/* Общие настройки */
.social-links {
    list-style: none;
    margin: 0;
    padding: 0;
}

/* В верхней панели (utilitybar) — в строку */
.utilitybar .social-links {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
}

.utilitybar .social-links li {
    display: inline-block;
}

.utilitybar .social-links a {
    color: #fff;
    font-size: 16px;
    transition: color 0.3s;
}

.utilitybar .social-links a:hover {
    color: #5e5c5c;
}

/* В подвале (footer) — столбиком */
.site-footer .social-links {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.site-footer .social-links li a {
    text-decoration: none;
    color: #fff;
    transition: color 0.2s;
}

.site-footer .social-links li a:hover {
    color: #00aced;
}

/* === Social — гарантируем горизонтальное отображение в шапке === */
.ubar-right .socialicons,
.ubar-right .socialicons ul,
.utilitybar .social-links,
.utilitybar .socialicons > ul {
  display: flex;
  flex-direction: row;
  gap: 12px;
  align-items: center;
}

/* На всякий случай — если include отдаёт только <li> без <ul> */
.ubar-right .socialicons > li,
.ubar-right .socialicons li {
  display: inline-flex;
}

/* ===== Шапка ===== */
.site-header {
    background: linear-gradient(to right, #000000 5%, #1a1a80 25%, #110270 75%,  #000000 100%);
    position: sticky;
    top: 0;
    z-index: 1000;
    height: clamp(100px, 8vw, 150px);
    overflow: hidden;    /* ничего не вылезает */
    box-shadow: 0 2px 10px rgba(0,0,0,0.4); /* тень под шапкой */
}

.site-header::before {
    content: "";
    position: absolute;
    inset: 0; /* растягиваем на весь header */
    background: url("../images/decor2.png") no-repeat center/cover;
    background-size: min(95%, 1400px) auto;
    background-position: center;
}

.headerinnerwrap {
    position: relative;
    z-index: 2;

    width: min(95%, 1400px);
    max-width: 100%;
    margin: 0 auto;
    padding: 0 2rem;
    height: 100%;

    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

/* Контейнер логотипа */
.logo-wrapper {
    position: relative;
    display: flex;
    align-items: flex-end;
    height: 80%;
    overflow: hidden;
    transform: translateX(-50px);
}

/* Основное PNG-изображение логотипа */
.icraft-logo {
    position: relative;
    z-index: 2; /* выше анимации */
    max-height: clamp(70px, 7vw, 140px);
    width: auto;
    display: block;

    filter: drop-shadow(0 0 1px rgba(255, 255, 255, 0.9))
            drop-shadow(0 0 3px rgba(0, 123, 255, 0.6));
    transition: filter 0.3s ease;
}

/* Эффект при наведении */
.icraft-logo:hover {
    filter: drop-shadow(0 0 4px rgba(255, 255, 255, 1))
            drop-shadow(0 0 8px rgba(0, 123, 255, 0.8));
}

/* SVG-анимация поверх логотипа */
.logo-anim {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none; /* чтобы не мешала кликам */
    z-index: 1; /* ниже логотипа */
}

.logo-anim text {
    fill: rgba(255, 255, 255, 0); /* полупрозрачный белый */
    stroke: none;                    /* убрать обводку */
    font-size: 80px;
    font-family: "Segoe UI", Tahoma, sans-serif;
    text-shadow: 0 0 6px rgba(255, 255, 255, 0.3); /* лёгкое свечение */
}

#sparks circle {
  opacity: 0.9;
  transition: opacity 0.3s ease-in-out;
}

/* Меню */
.nav-menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: clamp(10px, 2vw, 25px);
    flex-wrap: wrap;
}

.nav-menu li {
    display: inline-block;
}

.nav-menu a {
    color: #fff;  /* белое меню */
    font-weight: 600;
    padding: 10px 0;
    position: relative;
    text-shadow: 0 0 6px rgba(255, 255, 255, 0.8),
                 0 0 12px rgba(0, 123, 255, 0.6); /* мягкое свечение */
    transition: color 0.3s ease;
    white-space: nowrap;
}

/* Активный пункт */
ul.nav-menu > li.tx-heighlight > a {
    color: #6b6a6a;
    font-weight: 700;
}

/* Подсветка снизу при hover */
.nav-menu a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background: #ff6600;
    transition: width 0.3s ease;
}

.nav-menu a:hover {
    color: #aad4ff; /* чуть голубее */
    text-shadow: 0 0 8px rgba(255, 255, 255, 1),
                 0 0 16px rgba(0, 123, 255, 0.8); /* сильнее светится */
}

.nav-menu a:hover::after {
    width: 100%;
}

/* ===== Hero и Articles ===== */
.hero,
.articles {
    position: relative;
    color: #fff;
    text-align: left;
    padding: 10px 20px;
    background: rgba(0, 0, 0, 0.4); /* полупрозрачный тёмный фон */
    border-radius: 12px;
    max-width: 100%;
    margin: 10px auto 40px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}

.hero h1,
.articles h2 {
    font-size: 2.3rem;
    margin-bottom: 20px;
    text-shadow: 0 2px 6px rgba(0,0,0,0.8);
    text-align: center;
}

.hero p,
.hero ul,
.articles p,
.articles ul {
    font-size: 1.5rem;
    line-height: 1.6;
    text-shadow: 0 1px 3px rgba(0,0,0,0.7);
    max-width: 100%;
    margin: 0 auto 20px;
}

.hero ul {
    padding-left: 20px;
}

.hero .btn {
    display: inline-block;
    margin-top: 25px;
    padding: 12px 24px;
    background: rgba(131, 131, 133,0.1);
    color: #fff;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    box-shadow: 0 3px 8px rgba(0,0,0,0.5);
    transition: background 0.3s, transform 0.2s;
}

.hero .btn:hover {
    background: rgba(219, 219, 219,0.3);
    transform: translateY(-2px);
}

/* Статьи */
.articles .article-item {
    background: rgba(255, 255, 255, 0.1); /* светлая подложка под статью */
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}

.articles .article-item h3 {
    margin-bottom: 10px;
    font-size: 1.4rem;
    color: #ffd369;
}

/* ===== Контент ===== */
main#content {
    max-width: 100%;
    margin: 30px auto;
    padding: 0 20px;
}

.content-wrapper {
    width: min(95%, 1400px);
    margin: 0 auto;
    padding: 2rem;

    background-image: url("../images/carbon6.png");
    background-size: auto;
    background-repeat: repeat;
    background-position: top center;
}

/* ===== Подвал ===== */
.site-footer {
    background: linear-gradient(to right, #000000 5%, #1a1a80 25%, #110270 75%,  #000000 100%);
    color: #fff;
    padding: 15px 20px;
}

.footer-bg {
    max-width: 1200px;
    margin: 0 auto;
}

.footer-columns {
    display: flex;
    justify-content: space-between; /* равномерно распределить */
    gap: 15px;                      /* расстояние между колонками */
}

.footer-contacts {
    flex: 1;
    min-width: 180px;
}

.footer-certificates {
    flex: 2;
    min-width: 300px;
}

.footer-social {
    flex: 1;
    min-width: 180px;
}

.footer-column h4 {
    margin: 0 0 10px;
}

.footer-cert-thumb {
    width: 60px;   /* размер иконки */
    height: auto;
    cursor: pointer;
    border: 1px solid #ccc;
    border-radius: 4px;
    transition: transform 0.2s ease;
}

.footer-cert-thumb:hover {
    transform: scale(1.1);
    border-color: #666;
}

.footer-cert-link {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #fff;
}

.footer-cert-link span {
    line-height: 1.3;
}

/* Адаптив для колонок */
@media (max-width: 768px) {
    .footer-columns {
        flex-direction: column;     /* на телефоне одна под другой */
        gap: 30px;
    }
}

.site-info {
    margin-top: 10px;
    border-top: 1px solid #555;
    padding-top: 8px;
    display: flex;
    justify-content: space-between;
    font-size: 14px;
}

/* ===== Адаптив ===== */
@media (max-width: 768px) {
    .headerinnerwrap {
        flex-direction: column;
        align-items: flex-start;
    }

    .nav-menu {
        flex-direction: column;
        gap: 10px;
        width: 100%;
    }

    .site-info {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }

    /* --- Колонки контента --- */
    .content-layout {
        flex-direction: column; /* ставим одну под другой */
    }

    .sidebar-left,
    .content-wrapper {
        width: 100%;
        max-width: 100%;
    }
}

/*===== Слайдер =====*/
.slider {
  width: 100%;
  max-width: 95%;
  margin: 0 auto 40px;
  position: relative;
  overflow: hidden;
  border-radius: 8px;
}

/* Кнопки */
.slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: transparent !important;
  color: transparent !important;
  border: none !important;
  opacity: 0;
  padding: 10px 15px;
  cursor: pointer;
  z-index: 2;
}

.slider-btn.prev { left: 10px; }
.slider-btn.next { right: 10px; }

.slider-track {
    position: relative;
    height: clamp(320px, 20vw, 260px);
}

.slide {
    position: absolute;
    inset: 0;

    width: 100%;
    height: 100%;

    opacity: 0;
    transition: opacity 1.5s ease;

    overflow: hidden;
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 50% 90%;

    transform: scale(1);
    transition:
        transform 15s linear,
        opacity 1.5s ease;
}

.slide.active img {
    transform: scale(1.10);
}

.slide.active {
    opacity: 1;
    z-index: 2;
}

/* Текст поверх картинки */
.caption {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  color: #fff;
  text-align: center;
  background: rgba(0,0,0,0.0); /* убрал фон */
  padding: 10px 20px;
  border-radius: 6px;
  max-width: 1200px;
}

.caption h2 {
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: bold;
  margin: 0 0 10px;  /* отступ снизу */
  text-shadow:
    -1px -1px 0 #000,
     1px -1px 0 #000,
    -1px  1px 0 #000,
     1px  1px 0 #000,
     2px  2px 6px rgba(0,0,0,0.7);
}

.caption p {
  font-size: clamp(0.9rem, 1.5vw, 1.2rem);
  margin: 0;
  text-shadow:
    -1px -1px 0 #000,
     1px -1px 0 #000,
    -1px  1px 0 #000,
     1px  1px 0 #000,
     2px  2px 6px rgba(0,0,0,0.7);
}

/* Адаптив */
@media (max-width: 768px) {
  .slide {
    height: 220px;
  }
  .caption {
    font-size: 14px;
    padding: 8px 12px;
  }
}

/* =====Статьи=====*/
article {
    text-shadow: none;  /* отключаем обводку */
}

.article-container {
    display: flex;
    justify-content: space-between;
    margin: 30px auto;
    padding: 20px;
}

.article-content {
    max-width: 1200px;
    width: 100%;
    background-color: rgba(252, 252, 252,0.92); /* фон */
    background-image:
        radial-gradient(rgba(0,0,0,0.04) 20px, transparent 20px);
    background-size: 5px 5px; /* размер зерна */
    color: #000000; /* текст */
    padding: clamp(1rem, 2vw, 2rem);
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    line-height: 1.7;
    font-size: clamp(1rem, 1.3vw, 1.35rem);
}

.article-content h1 {
    margin-bottom: 20px;
    font-size: 2rem;
    color: #030303; /* заголовок чёрный */
}

.article-content a[id] {
    font-weight: 700;
    text-decoration: none;
    color: #2d004d !important;
}

.article-body img.left {
    float: left;
    margin: 10px 20px 10px 0;
    max-width: 10%;
    height: 10%;
}

/*===== Сервис. Меню =====*/
.service-menu {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: clamp(10px, 2vw, 30px);
    align-items: start;
    justify-items: center;
    width: 100%;
    margin-top: 25px;
}

/* Каждый элемент меню */
.menu-item {
    width: 100%;
    text-align: center;
    position: relative;
}

/* Картинки растягиваются по колонке, но с сохранением пропорций */
.menu-item img {
    width: 100%;
    max-width: 180px;
    height: auto;
    display: block;

    border-radius: 10px;
    cursor: pointer;
    transition: transform 0.3s ease;
}

/* При наведении немного увеличиваются */
.menu-item img:hover {
    transform: scale(1.05);
}

/* Текст под картинкой */
.menu-item p {
    margin-top: 8px;
    color: #ffffff;
    white-space: normal;
    word-wrap: break-word;
    font-size: 14px;
}

/* Выпадающее меню */
.dropdown {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.1);
    border: none;
    border-radius: 8px;
    padding: 10px;
    z-index: 10;
    backdrop-filter: blur(4px);
}

.dropdown a {
    display: block;
    padding: 5px;
    color: #ffffff;
    text-decoration: none;
}

.dropdown a:hover {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 5px;
}

.menu-item:hover .dropdown {
    display: block;
}

/* ===== Левая колонка с новостями =====*/
.content-layout {
    display: flex;
    gap: 40px;
    max-width: 100%;
    margin: 20px auto;
    padding: 0 20px;
    align-items: flex-start;
}

.sidebar-left {
    flex: 0 0 20%; /* фиксированная ширина колонки*/
    background: rgba(21, 12, 117,0.9);
    border-radius: 8px;
    padding: 15px;
    color: #d7d7d9;
}

.sidebar-left .news-block {
    margin-bottom: 20px;
}

.sidebar-left .news-block h3 {
    font-size: 1.1em;
    margin-bottom: 10px;
    color: #ffd369;
    border-bottom: 1px solid #444;
    padding-bottom: 5px;
}

.sidebar-left .news-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.sidebar-left .news-list li {
    margin-bottom: 8px;
    font-size: 0.95em;
}

.sidebar-left .news-list a {
    text-decoration: none;
    color: #aad4ff; /* читаемый цвет для ссылок*/
    transition: color 0.2s ease;
}

.sidebar-left .news-list a:hover {
    color: #ffd369;
}

/*=== Иконки===*/
.icon {
    width:80px;
    height: 80px;
    vertical-align: middle;
    margin-right: 10px;
}

/* ===== Контейнер ===== */
.image-wrapper {
    position: relative;
    width: 100%;
    max-width: 220px;
    aspect-ratio: 5 / 3;
    overflow: hidden;
    border-radius: 10px;
}

/* ===== ОБА изображения ===== */
.image-wrapper {
    position: relative;
    width: 100%;
    max-width: 220px;
    aspect-ratio: 5 / 3;
    overflow: hidden;
    border-radius: 10px;
}

.image-wrapper img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: clip-path 3.5s ease-in-out;
}

.image-wrapper img.img-main {
    clip-path: inset(0 0 0 0);
}

.image-wrapper img.img-alt {
    clip-path: inset(0 100% 0 0);
}

/* ВАЖНАЯ анимация */
.image-wrapper.show-alt img.img-main {
    clip-path: inset(0 0 0 100%);
}

.image-wrapper.show-alt img.img-alt {
    clip-path: inset(0 0 0 0);
}

.image-wrapper.no-transition img {
    transition: none !important;
}

.section-divider {
    width: 100%;
    height: 3px;
    margin: 50px 0 25px;
    border-radius: 3px;
    background: linear-gradient(
        90deg,
        transparent,
        #0077cc,
        #00c2ff,
        #0077cc,
        transparent
    );
}

@media (max-width: 900px) {
    .service-menu {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 500px) {
    .service-menu {
        grid-template-columns: 1fr;
    }
}

.language-switcher{
    display:flex;
    align-items:center;
    gap:6px;
    margin-right:20px;
}

.language-switcher button{
    background:none;
    border:none;
    padding:0;
    color:#bdbdbd;
    font-size:14px;
    font-weight:600;
    cursor:pointer;
    transition:0.2s;
}

.language-switcher button:hover{
    color:#ffffff;
}

.language-switcher button.active{
    color:#2fa8ff;
}

.language-switcher span{
    color:#777;
}


