@font-face {
    font-family: 'League Spartan';
    src: url('/font/LeagueSpartan-ExtraBold.ttf') format('truetype');
    font-weight: 800; /* ExtraBold обычно соответствует 800 */
    font-style: normal;
    font-display: swap; /* улучшает производительность загрузки */
}
@font-face {
    font-family: 'Neue Cyrillic';
    src: url('/font/bebasneuecyrillic.ttf') format('truetype');
    font-weight: 800; /* ExtraBold обычно соответствует 800 */
    font-style: normal;
    font-display: swap; /* улучшает производительность загрузки */
}
.railcore-text {
    top: 80px;
    z-index: -1;
    position: absolute;
    width: 100%;
    text-align: center;
}
.logo-font {
    font-family: 'League Spartan', sans-serif;
    font-weight: 800;
    font-size: 20.5vw;
}
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    background-color: #fff;
    color: #1e293b;
    scroll-behavior: smooth;
}

/* Центрирующий контейнер для блоков 2-5 */
.container {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 40px;
}

/* Общие стили блоков */
.block {
    width: 100%;
}

/* ========== БЛОК 1 ========== */
.hero {
    position: relative;
    width: 100%;
    height: 800px;
    background-image: url('/img/cover_without_bg_big.png');
    background-size: 100%;
    background-position: 50% 244px;
    background-repeat: no-repeat;
}
/*
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.45);
    z-index: 1;
}
*/
/* Верхняя панель (лого + иконки) */
.top-bar {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 20;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.2s;
}
/* Для мобильных — закрепляем вверху */
.top-bar.fixed-mobile {
    position: fixed;
    top: 0;
    left: 0;
    background: white;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    animation: slideDownFixed 0.3s ease;
}
@keyframes slideDownFixed {
    from { transform: translateY(-100%); }
    to { transform: translateY(0); }
}

.top-bar-inner {
    max-width: 1440px;
    margin: 0 auto;
    padding: 16px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.logo a {
    display:block;
    width: 173px;
    height: 26px;
    background: url('/img/Railcore_top.png') 100% 100%;
    position: relative;
    background-image: url('/img/Railcore_top.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;

}

/* Иконки справа */
.icons-group {
    display: flex;
    gap: 28px;
    align-items: center;
}
.icons-group span {white-space: nowrap;}
.icon-link {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: #1f3e48;
    font-weight: 500;
    transition: color 0.2s;
    font-size: 0.95rem;
}
.icon-link:hover { color: #0f6b8c; }
.icon-link svg {
    width: 22px;
    height: 22px;
    stroke: currentColor;
    fill: none;
}

/* Мобильная кнопка меню */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: #0071C5;
    font-size: 1.5rem;
    padding: 0 10px;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    gap: 6px;
    align-items: center;
    font-family: inherit;
}

/* Десктоп навигация */
.desktop-nav {
    display: flex;
    gap: 2rem;
    margin-left: 7rem;
    margin-right: 1.5rem;
}
.desktop-nav a {
    text-decoration: none;
    font-weight: 500;
    color: #1f3e48;
    font-size: 1rem;
    transition: 0.2s;
}
.desktop-nav a:hover { color: #0f6b8c; }

/* Мобильное меню оверлей */
.mobile-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 2000;
    display: none;
    justify-content: center;
    align-items: flex-start;
    padding-top: 90px;
}
.mobile-menu-panel {
    background: white;
    width: 86%;
    max-width: 340px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 20px 35px rgba(0,0,0,0.2);
    animation: panelPop 0.2s ease;
}
@keyframes panelPop {
    from { opacity: 0; transform: translateY(-15px);}
    to { opacity: 1; transform: translateY(0);}
}
.mobile-menu-panel ul { list-style: none; }
.mobile-menu-panel li { border-bottom: 1px solid #edf2f7; }
.mobile-menu-panel a {
    display: block;
    padding: 1.8rem 1.8rem;
    text-decoration: none;
    font-size: 1.5rem;
    font-weight: 500;
    color: #1f3e48;
}
.close-menu-mob {
    text-align: right;
    padding: 0.8rem 1rem;
    border-bottom: 1px solid #e2e8f0;
}
.close-menu-mob button {
    background: none;
    border: none;
    font-size: 1.1rem;
    color: #5c7c8a;
    cursor: pointer;
}


/* ========== БЛОК 2 ========== */
.block-2 { padding: 80px 0; background: #fff; }
.two-col-layout {
    display: flex;
    justify-content: space-between;
    gap: 80px;
    flex-wrap: wrap;
}
.left-col-50 { flex: 1; min-width: 280px; }
.right-col-50 { flex: 1; min-width: 280px; }
.blue-title { color: #0071C5; font-size: 3rem; font-family: 'Neue Cyrillic', sans-serif; margin-bottom: 1rem; }
.gray-text { color: #8D8D8D; line-height: 1.5; text-transform:none;}
.about-highlight-text {
    color: #2d3748;
    font-size: 1rem;
    line-height: 1.5;
    max-width: 90%;
    margin-top: 0;
}
#about p {padding:12px 0}

/* ========== БЛОК 3 (4 карточки) ========== */
.block-3 { background: #f9fbfd; padding: 80px 0; }
.services-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 20px;
    text-transform: uppercase;
    margin-bottom: 20px;
}
.cards-row {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: space-between;
}
.service-card {
    flex: 1 1 22%;
    min-width: 240px;
    background: white;
    border-radius: 28px;
    padding: 24px 24px 32px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.04);
    transition: transform 0.2s;
}
.card-number {
    font-size: 3rem;
    font-weight: 800;
    color: #cbd5e1;
    text-align: right;
    line-height: 1;
    margin-bottom: 20px;
}
.card-title { font-size: 1.4rem; font-weight: 700; color: #1a2c3e; margin: 20px 0 12px; }
.card-text { color: #4a5b6e; line-height: 1.45; }

/* ========== БЛОК 4 (партнеры с логотипами) ========== */
.block-4 { background: #fff; padding: 80px 0; }
.partner-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: space-between;
    margin-top: 50px;
}
.partner-logo {
    flex: 1 1 150px;
    min-width: 140px;
    max-width: 200px;
    height: 100px;
    background: #f2f5f9 url('/img/cola.png') center/80% no-repeat;
    border-radius: 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.03);
    transition: all 0.2s;
}

/* ========== БЛОК 5 (контакты + форма) ========== */
.block-5 { background: #f4f9fe; padding: 80px 0; }
.contact-split {
    display: flex;
    flex-wrap: wrap;
    gap: 50px;
    margin-top: 50px;
}
.info-col { flex: 1; min-width: 280px; }
.form-col { flex: 1; min-width: 280px; }
.info-item { margin-bottom: 32px; }
.info-label { font-size: 0.85rem; font-weight: 600; text-transform: uppercase; color: #5c8daa; letter-spacing: 1px; margin-bottom: 8px; }
.info-value { font-size: 1rem; color: #1e2f3c; line-height: 1.4; }
.contact-form input, .contact-form textarea {
    width: 100%;
    padding: 14px 18px;
    margin-bottom: 18px;
    border: 1px solid #dce5ec;
    border-radius: 8px;
    font-family: inherit;
    font-size: 0.95rem;
    background: white;
    transition: 0.2s;
}
.contact-form textarea { resize: vertical; min-height: 100px; }
.contact-form input:focus, .contact-form textarea:focus { outline: none; border-color: #2c9bcf; box-shadow: 0 0 0 2px rgba(44,155,207,0.2); }
.btn-send {
    background: #0071C5;
    color: white;
    border: none;
    padding: 14px 28px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: 0.2s;
    width: 100%;
}
.btn-send:hover { background: #0f5a78; }

/* ========== БЛОК 6 (футер) ========== */
.block-6 {
    background: #0071C5;
    color: white;
    padding: 50px 40px 30px;
}
.footer-container {
    max-width: 1440px;
    margin: 0 auto;
}
.footer-top {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid rgba(255,255,255,0.2);
}
.footer-logo-col {
    flex: 1;
    min-width: 180px;
}
.footer-logo {
    font-family: 'League Spartan', sans-serif;
    font-size: 2.8rem;
    font-weight: 800;
    color: white;
    background: none;
    white-space: nowrap;
}
.footer-logo a {
    text-decoration: none; /* убирает подчеркивание */
    color: inherit; /* наследует цвет родителя */
}
.footer-logo img {
    width: 44px;
    height: 30px;
}
.footer-links-col {
    flex: 1;
    min-width: 160px;
    display:flex;
    justify-content: center;
}
.footer-links-col ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.footer-links-col a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: opacity 0.2s;
}
.footer-links-col a:hover { opacity: 0.8; text-decoration: underline; }
.footer-icons-col {
    flex: 1;
    min-width: 180px;
    display: flex;
    justify-content: flex-end;
    gap: 24px;
}
.footer-icon-link {
    display: flex;
    align-items: center;
    gap: 8px;
    color: white;
    text-decoration: none;
    font-weight: 500;
}
.footer-icon-link svg {
    width: 28px;
    height: 28px;
    stroke: white;
    fill: none;
}
.footer-icon-link.whatsapp svg {
    stroke: #25D366;
}
.footer-icon-link.whatsapp:hover svg {
    stroke: #fff;
}
.footer-bottom {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
    padding-top: 30px;
    font-size: 0.85rem;
    opacity: 0.85;
}

.success-message {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
    padding: 10px;
    margin-top: 10px;
    border-radius: 4px;
}

.error-message {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    padding: 10px;
    margin-top: 10px;
    border-radius: 4px;
}

/* ========== АДАПТИВНОСТЬ ========== */
@media (max-width: 1320px) {
    .hero {height:720px;background-position-y:220px}
    .desktop-nav { display: none; }
}
@media (max-width: 1024px) {
    .service-card { flex: 1 1 45%; }
    .partner-logo { flex: 1 1 160px; }
    .hero {height:560px;background-position-y:200px}
}
@media (max-width: 768px) {
    .container { padding: 0 24px; }
    .hero::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 0;
        width: 100%;
        height: 24%;
        background: linear-gradient(to top, rgba(255, 255, 255, 0.95), rgba(0, 0, 0, 0));
        pointer-events: none;
        z-index:1;
    }
    .hero { 
        height: 100vh;
        background-size: cover;
        background-position: 50% 64px;
        background-image: url('/img/cover_mob.png'); 
    }
    .top-bar-inner { padding: 12px 20px; }
    .mobile-menu-btn { display: flex; }
    .icons-group { display: none; }
    .icons-group-mob {
        z-index:2;
        display: flex !important;
        position: absolute;
        bottom: 16vw;
        width: 100%;
        justify-content: space-around;
        padding: 0 20px;
    }
    .icons-group-mob .icon-link-mob {padding:10px}
    .icons-group-mob .icon-link-mob svg {
        width: 64px;
        height: 64px;
    }
    .two-col-layout { flex-direction: column; gap: 2px; }
    .about-highlight-text { max-width: 100%; }
    .blue-title { font-size: 2.4rem; }
    .services-header { flex-direction: column; align-items: flex-start; }
    .cards-row { flex-direction: column; }
    .service-card { width: 100%; }
    .partner-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    .partner-logo { min-width: auto; width: 100%; }
    .contact-split { flex-direction: column; }
    .footer-top { flex-direction: column; align-items: center; text-align: center; gap: 32px; }
    .footer-icons-col { justify-content: center; }
    .footer-links-col ul { align-items: flex-start; }
    .footer-bottom { flex-direction: column; align-items: center; text-align: center; }
    .block-6 { padding: 40px 24px 30px; }
    .railcore-text, .gray-text { display: none; }
    .footer-links-col {padding:20px 0}
    .footer-bottom span {display:block;width:100%}
}
@media (min-width: 769px) {
    .mobile-menu-btn { display: none; }
    .top-bar.fixed-mobile { position: absolute; }
}
@media (min-width: 1440px) {            
    .hero {height:870px;background-position-y:260px}
}
@media (min-width: 1610px) {
    .logo-font {font-size:340px;}
    .hero {height:920px;}
}
@media (min-width: 2210px) {
    .logo-font {font-size:340px;}
    .hero {height:1200px;}
}