        :root {
            --bg-dark: #0a1118;
            --accent-gold: #c5a059;
            --text-light: #e0e0e0;
            --text-muted: #8899a6;
            --card-bg: #141e27;
            --footer-bg: #050a0f;
        }

        body {
            font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
            background-color: var(--bg-dark);
            color: var(--text-light);
            margin: 0;
            line-height: 1.6;
            overflow-x: hidden; /* Prevent horizontal scroll from hero */
        }

        /* Typography & Utilities */
        a { text-decoration: none; transition: 0.3s; }
        ul { list-style: none; padding: 0; }
        
        /* Header */
        header {
            padding: 20px 5%;
            display: flex;
            justify-content: space-between;
            align-items: center;
            background: rgba(10, 17, 24, 0.95);
            position: sticky;
            top: 0;
            z-index: 1000;
            border-bottom: 1px solid #1a2a3a;
            backdrop-filter: blur(10px);
        }

        .logo {
            font-weight: bold;
            color: var(--accent-gold);
            font-size: 1.2rem;
            letter-spacing: 1px;
            text-transform: uppercase;
			transition: color 0.5s ease, opacity 0.5s ease;
        }
		.logo:hover {
			opacity: 0.8;
			color: #fff;
		}		
        nav a {
            color: var(--text-light);
            margin-left: 25px;
            font-size: 0.9rem;
        }
        nav a:hover { color: var(--accent-gold); }	

		/* Burger button */
		.burger {
			display: none;
			background: none;
			border: none;
			cursor: pointer;
			padding: 10px;
		}

		.burger span {
			display: block;
			width: 24px;
			height: 2px;
			background: var(--text-light);
			margin: 5px 0;
			transition: 0.3s;
		}
		
		.burger.active span:nth-child(1) {
			transform: rotate(45deg) translate(5px, 5px);
		}

		.burger.active span:nth-child(2) {
			opacity: 0;
		}

		.burger.active span:nth-child(3) {
			transform: rotate(-45deg) translate(6px, -6px);
		}

		/* Mobile */
		@media (max-width: 768px) {
			.burger {
				display: block;
			}

			nav {
				display: none;
				flex-direction: column;
				width: 100%;
				margin-top: 15px;
			}

			nav.active {
				display: flex;
			}

			nav a {
				margin: 0;
				padding: 12px 0;
				border-top: 1px solid #1a2a3a;
			}

			nav a:first-child {
				border-top: none;
			}

			header {
				flex-wrap: wrap;
				align-items: center;
			}
		}	
				
	

		

        /* Hero Section */
        .hero {
            min-height: 93vh;
            display: flex;
            flex-direction: column;
            justify-content: center;
            align-items: center;
            text-align: center;
            padding: 20px 10%;
			background: 
				linear-gradient(
					to bottom,
					rgba(10, 17, 24, 0.85) 0%,
					rgba(10, 17, 24, 0.80) 40%,
					rgba(10, 17, 24, 0.75) 50%,
					rgba(10, 17, 24, 0.85) 60%,
					rgba(10, 17, 24, 0.98) 100%
				),
				url('../images/printed circuit board.avif') center/cover;
            background-attachment: fixed;
        }
		
		.hero-logo {
			width: 120px;
			height: auto;
			margin-bottom: 4px;
			display: block;
		}

        .hero h1 {
            font-size: 3.5rem;
            margin-bottom: 20px;
            max-width: 1100px;
            line-height: 1.1;
            color: #fff;
        }

        .hero p {
            font-size: 1.3rem;
            max-width: 800px;
            margin-bottom: 50px;
			color: var(--text-light);
			opacity: 0.8;
			letter-spacing: 0.3px;
			text-shadow: 0 2px 10px rgba(0,0,0,0.5);
        }
		
		
		
		
        /* Buttons */
        .btn-group { 
			display: flex;
			gap: 20px;
			/*flex-wrap: wrap;*/
		}		
		.btn-group .btn {
			/*flex: 1 1 auto;
			min-width: 0;*/
			text-align: center;
			display: inline-block;
		}
        .btn {
            padding: 15px 35px;
            border-radius: 4px;
            font-weight: bold;
            display: inline-block;
			text-align: center;
			transition: 0.3s
        }
        .btn-primary { background-color: var(--accent-gold); color: #000; }
        .btn-secondary { border: 1px solid var(--accent-gold); color: var(--accent-gold); }
        .btn:hover { transform: translateY(-2px); filter: brightness(1.1); }

		.cta-block .btn-group {
			display: flex;
			gap: 20px;
			justify-content: center;
			max-width: 800px;
			margin: 0 auto;
		}
		.cta-block .btn-group .btn {
			text-align: center;
			display: inline-block;
			min-width: 0;
		}
		@media (max-width: 480px) {
			.btn-group {
				flex-direction: column;
			}
			.btn-group .btn {
				width: 100%;
			}		
			.cta-block .btn-group {
				flex-direction: column;
			}
			.cta-block .btn-group .btn {
				width: 100%;
			}
		}
				
		
		
		

        /* Expertise Stats Bar */
        .expertise-bar {
            background: #0d161f;
            padding: 60px 10%;
			/*border-top: 1px solid #1a2a3a;*/
            border-bottom: 1px solid #1a2a3a;
        }
		
		.stats-grid {
			display: grid;
			grid-template-columns: repeat(4, 1fr);
			gap: 20px;
			text-align: center;
			width: 100%;
			margin: 0 auto;
			align-items: stretch; /* Важно для одинаковой высоты колонок */
		}

		.stat-item {
			display: flex;
			flex-direction: column;
			justify-content: flex-start; /* Заголовки сверху */
			height: 100%;
		}

		.stat-item h4 {
			font-size: 2.2rem; /* Немного уменьшил, чтобы "Vendor-Neutral" не ломало строку */
			color: var(--accent-gold);
			margin: 0;
			line-height: 1.2;
			min-height: 2.4em; /* Резервируем место под 2 строки, чтобы оси совпали */
			display: flex;
			align-items: center; /* Центрируем текст заголовка по вертикали */
			justify-content: center;
		}

		.stat-item p {
			color: var(--text-muted);
			font-size: 0.85rem;
			text-transform: uppercase;
			letter-spacing: 1px;
			margin-top: auto; /* МАГИЯ: забирает всё свободное место сверху и толкает текст вниз */
			padding-top: 15px;
		}
		
		
		#expertise {
		  scroll-margin-top: 72px; /* высота хедера */
		}
		
		
		
		/* --- Бесконечная петля логотипов заказчиков --- */
		.clients-section {
			background: #0a1118;
			padding: 60px 0;
			overflow: hidden;
			position: relative;
			border-bottom: 1px solid #1a2a3a; 
		}

		.clients-section::before,
		.clients-section::after {
			content: "";
			position: absolute;
			top: 0;
			width: 150px;
			height: 100%;
			z-index: 2;
			pointer-events: none;
		}

		.clients-section::before {
			left: 0;
			background: linear-gradient(to right, #0a1118, transparent);
		}

		.clients-section::after {
			right: 0;
			background: linear-gradient(to left, #0a1118, transparent);
		}

		.marquee {
			overflow: hidden;
			width: 100%;
		}

		.marquee-track {
			display: flex;
			width: max-content;
			will-change: transform;
		}

		.marquee-group {
			display: flex;
			align-items: center;
			gap: 60px;
		}

		.marquee-group img {
			height: 100px;
			width: auto;
			object-fit: contain;
			filter: grayscale(100%) invert(1) opacity(0.5);
			transition: all 0.4s ease;
			padding: 10px;
			border-radius: 4px;
		}

		.marquee-group img:hover {
			filter: none;
			background: #fff;
			transform: scale(1.04);
		}
		
		
		
        /* Sections General */
        section { padding: 80px 10%; }
        h2 {
            text-align: center;
            color: var(--accent-gold);
            font-size: 2rem;
            margin-bottom: 20px;
            text-transform: uppercase;
            letter-spacing: 2px;
        }
        .section-subtitle {
            text-align: center;
            color: var(--text-muted);
            margin-bottom: 60px;
            max-width: 1000px;
            margin-left: auto;
            margin-right: auto;
        }
		@media (max-width: 768px) {
			h2 { font-size: 1.2rem; }
		}
		
		

        /* Cards Grid */
        .grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
            gap: 30px;
        }
		
		.case-grid {
            display: grid;
            grid-template-columns: repeat(3, 1fr);
            gap: 30px;
        }	
		
		.features-grid {
            display: grid;
            grid-template-columns: repeat(4, 1fr);
            gap: 30px;
        }

		
        .card {
            background: var(--card-bg);
            padding: 35px;
            border-radius: 8px;
            border-bottom: 3px solid transparent;
            display: flex;
            flex-direction: column;
            transition: 0.3s;
        }		
        .case-card {
            background: var(--card-bg);
            padding: 35px;
            border-radius: 8px;
            border-bottom: 3px solid transparent;
            display: flex;
            flex-direction: column;
            transition: 0.3s;
        }		
        .card:hover, .case-card:hover {
            border-bottom: 3px solid var(--accent-gold);
            background: #1c2935;
            transform: translateY(-5px);
        }
        .card h3, .case-card h3 { 
			margin-top: 0; 
			color: var(--text-light); 
			font-size: 1.4rem; 
		}		
        .card h3 span, case-card h3 span {
            display: block;
            font-size: 0.9rem;
            color: var(--accent-gold);
            margin-bottom: 10px;
            text-transform: uppercase;
            letter-spacing: 1px;
        }
		
		.card p  {
			margin-top: auto;
		}
		.case-card p  {
			margin-top: 0;
		}
		
        .card-link {
            margin-top: auto;
            padding-top: 20px;
            color: var(--accent-gold);
            font-weight: bold;
            font-size: 0.9rem;
        }

		@media (max-width: 1720px) {
			.features-grid {
				grid-template-columns: repeat(2, 1fr);
			}
		}		
		
		@media (max-width: 768px) {
			section {
				padding: 60px 20px;
			}
			.grid, .case-grid, .features-grid {
				grid-template-columns: 1fr;
			}
			.card, .case-card {
				padding: 25px;
			}
		}
				


		
		

        /* Case Studies specific */
        .case-formula {
            font-size: 0.9rem;
            margin-top: 20px;
            padding-top: 20px;
            border-top: 1px solid #2a3a4a;
        }
        .tag { font-weight: bold; color: #7b9bb3; margin-right: 5px; }
        .result-highlight { color: var(--accent-gold); font-weight: bold; }
		
		
		
		
		/* Галерея */
		
		/* Контейнер для выравнивания стрелок по бокам сетки */
		.gallery-wrapper {
			display: flex;
			align-items: center;
			justify-content: center;
			gap: 20px;
			margin: 0 auto;
		}

		/* Стили кнопок-стрелок */
		.nav-btn {
			background: none;
			border: none;
			cursor: pointer;
			padding: 10px;
			transition: 0.3s;
			flex-shrink: 0;
		}

		.nav-btn img {
			width: 40px; /* Настройте под ваш макет */
			display: block;
		}

		/* Состояние "недоступен": обесцвечивание и полупрозрачность */
		.nav-btn.disabled {
			filter: grayscale(1) opacity(0.5);
			cursor: default;
			pointer-events: none;
		}

		/* Скрытие стрелок на мобильных устройствах */
		@media (max-width: 1720px) {
			.nav-btn {
				display: none;
			}
			.gallery-wrapper {
				display: block; /* Карточки будут идти друг под другом в составе сетки */
			}
			/* Заставляем ВСЕ карточки стать видимыми, игнорируя JavaScript */
			.case-grid .case-card {
				display: flex !important; /* !important перекрывает inline-стили от JS */
			}
			.case-grid {
				grid-template-columns: 1fr;
			}
			/* Сбрасываем расширение секции до стандартных 10% */
			/* !important нужен, так как в HTML теге прописан инлайновый стиль */
			#cases {
				padding-left: 10% !important;
				padding-right: 10% !important;
			}
			/* Обертка теперь просто блок без лишних зазоров */
			.gallery-wrapper {
				display: block;
				width: 100%;
				margin: 0;
			}
		}
		
		@media (max-width: 768px) {
			/* !important нужен, так как в HTML теге прописан инлайновый стиль */
			#cases {
				padding-left: 20px !important;
				padding-right: 20px !important;
			}
		}
		
		
		
		
		.cta-block {
            background: #0d161f;
			border: 1px dashed var(--accent-gold);
            padding: 40px;
			margin-top: 40px;
            text-align: center;       
        }
		
		

        /* Legal Footer Styles */
        footer {
            background: var(--footer-bg);
            padding: 60px 10% 20px;
            border-top: 1px solid #1a2a3a;
            font-size: 0.85rem;
            color: #888;
        }
		.footer-grid {
			display: grid; 
			/*grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));*/
			grid-template-columns: 1.5fr 0.8fr 1fr;
			gap: 40px; 
			margin-bottom: 40px;
		}		
		.footer-bottom {
			border-top: 1px solid #1a2a3a; 
			padding-top: 20px; 
			display: flex; 
			justify-content: space-between; 
			flex-wrap: wrap; 
			font-size: 0.75rem;		
		}
        .footer-col h5 {
            color: var(--text-light);
            font-size: 1rem;
            margin-bottom: 20px;
            margin-top: 0;
        }
        .legal-block p { margin: 5px 0; }
        .legal-links a {
            display: block;
            color: #888;
            margin-bottom: 8px;
            text-decoration: underline;
        }
        .legal-links a:hover { color: var(--accent-gold); }
        
        .methodology-note {
            background: #0d1218;
            padding: 15px;
            border-left: 2px solid #333;
            margin-top: 20px;
            font-size: 0.75rem;
            color: #666;
        }

        .copyright-row {
            border-top: 1px solid #1a2a3a;
            padding-top: 20px;
            display: flex;
            justify-content: space-between;
            align-items: center;
            flex-wrap: wrap;
            gap: 20px;
        }

        @media (max-width: 768px) {
            .hero h1 { font-size: 2rem; }
            .btn-group { flex-direction: column; width: 100%; }
            .stats-grid { grid-template-columns: 1fr 1fr; gap: 30px; }
            .footer-grid { grid-template-columns: 1fr; }
            .copyright-row { flex-direction: column; text-align: center; }
            .marquee-track { gap: 30px; } /* Smaller gap on mobile */
        }
		
				
		
		
		
		
		/* Контейнер для социальных ссылок */
		.social-links {
			margin: 15px 0; /* Отступы сверху и снизу */
			display: flex;
			flex-flow: row wrap;
			align-items: center;
			gap: 12px 8px;
		}

		.social-item {
			display: flex;
			align-items: center;
			gap: 8px;
			text-decoration: none;
			transition: all 0.2s ease;
			white-space: nowrap;
			color: #8899a6; /* Цвет как у остального текста в футере */
		}
		
		/* Создаем разделитель "|" через псевдоэлемент */
		.social-item:not(:last-child)::after {
			content: "|";
			margin-left: 2px;
			color: #1a2a3a; /* Цвет разделителя сделаем чуть ярче границ, но приглушенным */
			font-weight: normal;
			cursor: default;
		}

		.social-item:hover {
			color: #fff; /* Высветление при наведении */
			transform: translateY(-1px); /* Легкий эффект приподнимания */
		}

		.social-item i {
			font-size: 1.1rem;
			width: 20px;
			text-align: center;
		}

		.social-item a {
			color: inherit;
			text-decoration: none;
			font-weight: 500;
		}
		
		/* Стиль ссылки разработчика */
		.developer-link {
			text-decoration: none;
			color: inherit; /* Берет цвет #8899a6 от футера */
			transition: all 0.2s ease;
			display: inline-flex;
			align-items: center;
			gap: 6px; /* Отступ между текстом и иконкой */
		}

		/* Эффект при наведении на ссылку разработчика */
		.developer-link:hover {
			color: #fff;
			transform: translateY(-1px);
		}

		/* Размер иконки гиперссылки в ссылке разработчика*/
		.developer-link i {
			font-size: 0.7rem; /* Делаем её маленькой и аккуратной */
			opacity: 0.8;
		}
		
		/* Стили для ссылки-логотипа */
		.logo-link {
			text-decoration: none; /* Убираем подчеркивание */
			color: #fff; /* Основной цвет логотипа */
			transition: opacity 0.3s ease; /* Плавное изменение прозрачности */
		}

		.logo-link:hover {
			opacity: 0.8; /* Легкое высветление при наведении */
		}

		.logo span {
			transition: color 0.3s ease;
		}

		.logo-link:hover span {
			color: #fff !important; /* При наведении серая часть тоже становится ярче */
		}
		
		
		
		
		

		/* --- Набор стилей для модального окна --- */
		
		/* Глобальное правило для корректного расчета размеров */
		* {
			box-sizing: border-box;
		}
		
		/* Фоновая подложка окна*/
		.modal-overlay {
			display: none;
			position: fixed;
			top: 0; left: 0; width: 100%; height: 100%;
			background: rgba(5, 10, 15, 0.9);
			backdrop-filter: blur(5px);
			z-index: 1000;
		}

		/* Контейнер окна */
		.modal-content {
			position: relative;
			background: #0d161f;
			margin: 5% auto;
			padding: 40px;
			width: 95%;
			max-width: 800px;
			border: 1px solid #1a2a3a;
			color: #fff;
			border-radius: 8px;
			max-height: 90vh;  /* Чтобы окно не было длиннее экрана */
			overflow-y: auto;  /* Прокрутка внутри окна, если контент длинный */
		}

		/* Сетка: форма + контакты */
		.modal-grid {
			display: grid;
			grid-template-columns: 1.5fr 1fr;
			gap: 40px;
		}

		@media (max-width: 768px) {
			.modal-content {
				padding: 30px 15px 20px; /* Компактные отступы */
				margin: 5% auto;
			}
			
			.modal-grid {
				grid-template-columns: 1fr; /* Колонки встают друг под друга */
				gap: 30px;
			}

			.modal-info {
				padding-left: 0; /* Убираем те 12px на мобильных, чтобы не косило */
				border-top: 1px solid #1a2a3a; /* Визуально отделяем контакты */
				padding-top: 20px;
			}
			
			.modal-form input, .modal-form textarea {
				font-size: 16px; /* Предотвращает авто-зум на iPhone при фокусе */
			}
		}

		/* Поля ввода */
		.modal-form input, .modal-form textarea {
			width: 100%;
			padding: 12px;
			margin-bottom: 15px;
			background: #050a0f;
			border: 1px solid #1a2a3a;
			color: #fff;
			border-radius: 4px;
		}

		.close-modal {
			position: absolute;
			right: 20px; top: 10px;
			font-size: 30px; cursor: pointer; color: #8899a6;
		}
		
		/* Правая часть модального окна: контакты */
		.modal-info {
			padding-left: 24px; /* Тот самый отступ вправо */
		}

		/* На мобильных устройствах (до 768px) отступ лучше убрать, 
		   так как колонки встают друг под друга */
		@media (max-width: 768px) {
			.modal-info {
				padding-left: 0;
				margin-top: 20px; /* Добавим отступ сверху для разделения блоков на мобилках */
			}
		}
		
		/* Кнопка внутри модальной формы */
		.modal-form .btn {
			cursor: pointer;      /* Меняет курсор на "палец" */
			border: none;         /* Убирает стандартную рамку кнопки */
			width: 100%;          /* Растягиваем кнопку на всю ширину формы для удобства */
			display: block;
			text-align: center;
			transition: all 0.3s ease;
		}

		.modal-form .btn:hover {
			filter: brightness(1.1); /* Легкое высветление при наведении */
			box-shadow: 0 4px 15px rgba(197, 160, 89, 0.3); /* Золотистое свечение */
		}

		.modal-form .btn:active {
			transform: scale(0.98); /* Эффект нажатия (кнопка чуть вдавливается) */
		}
		
		.close-modal {
			cursor: pointer; /* Делает крестик кликабельным визуально */
		}

		/* Запрет выделения по умолчанию */
		body {
		  -webkit-user-select: none; /* Chrome, Safari */
		  -moz-user-select: none;    /* Firefox */
		  -ms-user-select: none;     /* Edge */
		  user-select: none;
		}

		/* Разрешение выделения в футере */
		footer,
		footer * {
		  -webkit-user-select: text;
		  -moz-user-select: text;
		  -ms-user-select: text;
		  user-select: text;
		}