*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    width: 100vw;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-Thin.ttf') format('truetype');
    font-weight: 100;
    font-style: normal;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-ThinItalic.ttf') format('truetype');
    font-weight: 100;
    font-style: italic;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-ExtraLight.ttf') format('truetype');
    font-weight: 200;
    font-style: normal;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-ExtraLightItalic.ttf') format('truetype');
    font-weight: 200;
    font-style: italic;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-Light.ttf') format('truetype');
    font-weight: 300;
    font-style: normal;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-LightItalic.ttf') format('truetype');
    font-weight: 300;
    font-style: italic;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-Italic.ttf') format('truetype');
    font-weight: 400;
    font-style: italic;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-Medium.ttf') format('truetype');
    font-weight: 500;
    font-style: normal;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-MediumItalic.ttf') format('truetype');
    font-weight: 500;
    font-style: italic;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-SemiBold.ttf') format('truetype');
    font-weight: 600;
    font-style: normal;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-SemiBoldItalic.ttf') format('truetype');
    font-weight: 600;
    font-style: italic;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-BoldItalic.ttf') format('truetype');
    font-weight: 700;
    font-style: italic;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-ExtraBold.ttf') format('truetype');
    font-weight: 800;
    font-style: normal;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-ExtraBoldItalic.ttf') format('truetype');
    font-weight: 800;
    font-style: italic;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-Black.ttf') format('truetype');
    font-weight: 900;
    font-style: normal;
}

@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-BlackItalic.ttf') format('truetype');
    font-weight: 900;
    font-style: italic;
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Raleway', Arial, sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    width: 100%;
    overflow-x: hidden;
}

.main-content {
    flex: 1;
    width: 100%;
}

/* HERO SECTION */
.hero {
    width: 100%;
    min-height: calc(100vh - 85px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: end;
    position: relative;
}

.hero::before {
    content: '';
    position: fixed;
    inset: 0;
    background: url('../images/header_1.avif');
    background-size: cover;
    background-position: 50% 0%;
    z-index: -10;
}

.hero-content {
    width: 100%;
    position: relative;
    z-index: 1;
    color: white;
    background: #00569d80;
    backdrop-filter: blur(10px);
    padding: 36px 0;
}

.hero-content-inner {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    text-align: start;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 32px;
    padding: 0 40px;
}

.hero-brand {
    position: relative;
    min-width: 0;
}

.hero-logo {
    margin-top: 10px;
    font-size: 80px;
    font-weight: 600;
    letter-spacing: 2px;
    color: transparent;
}

.hero-logo-image {
    position: absolute;
    width: auto;
    height: 125px;
    margin-right: 20px;
    transform: translate(-5px, 8px);
    user-select: none;
}

.hero-subtitle {
    /* Changed to inline-block so it wraps the text tightly instead of taking 100% width */
    display: inline-block;
    white-space: nowrap;
    font-size: 20px;
    margin-bottom: 24px;
    font-weight: 300;
    letter-spacing: 1px;
    transform: translate(80px, -8px);
}

.hero-buttons {
    display: flex;
    flex-direction: column;
    gap: 12px;
    justify-content: center;
    flex-shrink: 0;
}

.hero-btn {
    padding: 10px 40px;
    min-width: 220px;
    text-align: center;
    background: #ffffff15;
    border: 2px solid white;
    color: white;
    text-decoration: none;
    font-size: 16px;
    font-weight: 500;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.hero-btn:hover {
    background: white;
    color: #333;
}

.intro-section {
    width: 100%;
    background-color: #00569dd0;
    padding: 4px 0;
    backdrop-filter: blur(10px);
}

.intro-text {
    max-width: 1100px;
    margin: 0 auto;
    font-size: 17px;
    line-height: 1.75;
    color: #ffffff;
    text-align: center;
}

.sentence {
    display: flex;
    margin: 0;
    padding: 18px;
    color: #fff;
    width: 100%;
    height: auto;
    justify-content: center;
    align-items: center;
    font-size: 20px;
    font-weight: 500;
}

/* SYSTEMS SECTION */
.systems-section {
    width: 100%;
    padding: 80px 40px;
    background: white;
}

.section-title {
    text-align: center;
    font-size: 42px;
    color: #00579D;
    margin-bottom: 50px;
    font-weight: 700;
}

.systems-grid {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

.system-card {
    height: 300px;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.system-card-link {
    display: block;
    color: inherit;
    text-decoration: none;
}

.system-card-link:focus-visible .system-card,
.service-card-link:focus-visible {
    outline: 3px solid #ffffff;
    outline-offset: 3px;
}

.system-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, rgba(0, 99, 191, 0.072), rgba(0, 99, 191, 0.8));
    pointer-events: none;
}

.system-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

.system-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    user-select: none;
}

.system-title {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    color: white;
    padding: 15px;
    margin: 0;
    font-size: 22px;
    font-weight: 600;
    text-align: center;
}

/* SERVICES SECTION */
.services-section {
    width: 100%;
    padding: 80px 40px;
    padding-top: 0;
    background: #ffffff;
}

.services-grid {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.service-card {
    position: relative;
    background-size: cover;
    background-position: center;
    color: white;
    display: flex;
    flex-direction: column;
    min-height: 380px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-card-link {
    position: relative;
    display: flex;
    flex-direction: column;
    color: inherit;
    text-decoration: none;
    min-height: 380px;
    background-size: cover;
    background-position: center;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(#00599Dba, #112882ba);
    z-index: 1;
}

.service-card-overlay {
    position: relative;
    z-index: 2;
    padding: 40px 50px;
    display: flex;
    flex-direction: column;
    min-height: 480px;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}

.service-card-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(#00599Dba, #112882ba);
    z-index: 1;
}

.service-card-link:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}

.service-title {
    font-size: 32px;
    margin-bottom: 20px;
    font-weight: 700;
    text-align: center;
    color: white;
}

.service-description {
    font-size: 16px;
    line-height: 1.4;
    margin-bottom: auto;
    text-align: center;
    font-weight: 500;
    color: white;
}

.service-link {
    color: white;
    text-decoration: none;
    font-size: 22px;
    font-weight: 600;
    text-align: center;
    margin-top: 20px;
    transition: opacity 0.3s ease;
}

.service-card-link .service-link {
    display: block;
    pointer-events: none;
}

.service-link:hover {
    opacity: 0.8;
}

/* NEWS SECTION */
.news-section {
    width: 100%;
    padding: 80px 40px;
    background: #E9F9FF;
}

.news-container {
    max-width: 1100px;
    margin: 0 auto 30px;
}

.news-item {
    margin-bottom: 0;
    border-bottom: 2px solid #333;
}

.news-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 0;
    cursor: pointer;
}

.news-title {
    font-size: 22px;
    font-weight: 500;
    margin: 0;
    color: #333;
}

.news-toggle {
    background: none;
    border: none;
    font-size: 32px;
    font-weight: 300;
    color: #333;
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    user-select: none;
}

.news-content {
    height: 0;
    overflow: hidden;
    transition: height 0.3s cubic-bezier(.25, 0, .2, 1);
}

.news-content-inner {
    padding: 0 24px 25px 24px;
}

.news-content p {
    margin: 0;
    font-size: 12px;
    line-height: 1.8;
    color: #333;
}

.news-more {
    display: block;
    text-align: center;
    font-size: 18px;
    color: #333;
    font-style: italic;
    text-decoration: none;
    margin-top: 40px;
}

.news-more:hover {
    text-decoration: underline;
}

/* NEWS IMAGES GRID */
.news-images {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 0 24px 28px;
}

.news-img-thumb {
    position: relative;
    background: none;
    border: none;
    padding: 0;
    cursor: zoom-in;
    overflow: hidden;
    flex: 0 0 auto;
    outline: none;
}

.news-img-thumb::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0);
    transition: background 0.22s ease;
    pointer-events: none;
}

.news-img-thumb:hover::after {
    background: rgba(255, 255, 255, 0.22);
}

.news-img-thumb img {
    display: block;
    width: 150px;
    height: 100px;
    object-fit: cover;
    margin: 0;
    transition: transform 0.3s ease;
    user-select: none;
}

.news-img-thumb:hover img {
    transform: scale(1.06);
}

/* LIGHTBOX */
@keyframes lb-fade-in {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes lb-fade-out {
    from {
        opacity: 1;
    }

    to {
        opacity: 0;
    }
}

@keyframes lb-img-in {
    from {
        opacity: 0;
        transform: scale(0.96);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes lb-img-prev {
    from {
        opacity: 0;
        transform: translateX(-40px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes lb-img-next {
    from {
        opacity: 0;
        transform: translateX(40px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.news-lightbox {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(10, 10, 12, 0.96);
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.news-lightbox.open {
    display: flex;
    animation: lb-fade-in 0.2s ease forwards;
}

.news-lightbox.closing {
    display: flex;
    animation: lb-fade-out 0.18s ease forwards;
}

.lightbox-img-wrap {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    max-width: 90vw;
    max-height: 72vh;
    flex-shrink: 0;
}

.lightbox-img-wrap img {
    max-width: 88vw;
    max-height: 72vh;
    object-fit: contain;
    user-select: none;
    display: block;
}

.lightbox-img-wrap img.anim-in {
    animation: lb-img-in 0.22s ease forwards;
}

.lightbox-img-wrap img.anim-prev {
    animation: lb-img-prev 0.22s ease forwards;
}

.lightbox-img-wrap img.anim-next {
    animation: lb-img-next 0.22s ease forwards;
}

.lightbox-top-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 22px;
    z-index: 10001;
}

.lightbox-counter {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 1.5px;
    color: rgba(255, 255, 255, 0.5);
    user-select: none;
}

.lightbox-close {
    position: static;
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    padding: 4px 6px;
    transition: color 0.15s;
    z-index: 10001;
}

.lightbox-close:hover {
    color: #fff;
}

.lightbox-prev,
.lightbox-next {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.4);
    font-size: 48px;
    line-height: 1;
    cursor: pointer;
    padding: 20px 14px;
    transition: color 0.15s, background 0.15s;
    z-index: 10000;
    user-select: none;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.06);
}

.lightbox-prev {
    left: 0;
}

.lightbox-next {
    right: 0;
}

.lightbox-prev.hidden,
.lightbox-next.hidden {
    opacity: 0;
    pointer-events: none;
}

.lightbox-caption {
    margin-top: 14px;
    font-size: 12px;
    letter-spacing: 0.5px;
    color: rgba(255, 255, 255, 0.38);
    text-align: center;
    max-width: 70vw;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-transform: uppercase;
}

.lightbox-filmstrip {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    padding: 14px 20px;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.6));
    z-index: 10001;
}

.lb-film-thumb {
    width: 52px;
    height: 36px;
    object-fit: cover;
    cursor: pointer;
    opacity: 0.38;
    border: 2px solid transparent;
    transition: opacity 0.18s, border-color 0.18s;
    flex-shrink: 0;
    user-select: none;
}

.lb-film-thumb:hover {
    opacity: 0.75;
}

.lb-film-thumb.active {
    opacity: 1;
    border-color: #fff;
}

/* RESPONSIVE */
@media (max-width: 1024px) {
    .hero {
        min-height: calc(95vh - 85px);
    }

    /* Swap to tablet header image */
    .hero::before {
        background-image: url('../images/header_2.avif');
    }

    .hero-logo {
        display: none;
    }

    .hero-content {
        padding: 28px 0;
    }

    .hero-content-inner {
        padding: 0 30px;
        flex-direction: column;
        align-items: flex-start;
        gap: 24px;
    }

    /* Restore PC-like logo and subtitle positioning */
    .hero-brand {
        display: block;
        min-height: 85px;
        width: 100%;
    }

    .hero-logo-image {
        position: absolute;
        height: 82px;
        transform: translate(-5px, 0px);
        margin-right: 0;
    }

    .hero-subtitle {
        font-size: 18px;
        transform: translate(55px, 60px);
        margin-bottom: 0;
    }

    .hero-buttons {
        width: 100%;
        max-width: 520px;
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .hero-btn {
        width: 100%;
        min-width: 0;
        padding: 11px 16px;
        border-radius: 0;
        font-size: 15px;
        font-weight: 700;
        letter-spacing: 0.3px;
        border: 2px solid #ffffff;
        box-shadow: none;
    }

    .systems-section {
        padding: 60px 30px;
    }

    .systems-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .services-section {
        padding: 60px 30px;
        padding-top: 0;
    }

    .services-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
        width: 100%;
    }

    .service-card {
        min-height: 300px;
    }

    .service-card-overlay {
        min-height: 300px;
    }

    .news-section {
        padding: 60px 30px;
    }
}

@media (max-width: 768px) {
    .hero {
        min-height: calc(90vh - 85px);
    }

    /* Swap to mobile header image */
    .hero::before {
        background-image: url('../images/header_3.avif');
    }

    .hero-logo {
        font-size: 42px;
    }

    .hero-content {
        padding: 20px 0;
        backdrop-filter: blur(4px);
    }

    .hero-content-inner {
        padding: 0 20px;
        gap: 20px;
    }

    .hero-brand {
        min-height: 75px;
    }

    .hero-logo-image {
        height: 72px;
        transform: translate(-5px, 0px);
    }

    .hero-subtitle {
        font-size: 16px;
        transform: translate(50px, 55px);
    }

    .hero-buttons {
        width: 100%;
        max-width: 360px;
        grid-template-columns: 1fr;
    }

    .hero-btn {
        font-size: 14px;
        padding: 11px 14px;
        min-width: 0;
        width: 100%;
    }

    .systems-section {
        padding: 40px 20px;
    }

    .section-title {
        font-size: 32px;
        margin-bottom: 30px;
    }

    .systems-grid {
        grid-template-columns: 1fr;
        width: 100%;
    }

    .system-card {
        height: 200px;
    }

    .system-title {
        text-align: left;
    }

    .services-section {
        padding: 40px 20px;
        padding-top: 0;
    }

    .services-grid {
        grid-template-columns: 1fr;
        width: 100%;
    }

    .service-title {
        margin-bottom: 6px;
    }

    .service-description {
        text-align: left;
        font-size: 16px;
        line-height: 1.1;
        font-weight: 400;
    }

    .service-card-overlay {
        padding: 30px 20px;
    }

    .news-section {
        padding: 40px 20px;
    }
}

@media (max-width: 480px) {
    .hero-content {
        padding: 16px 0;
    }

    .hero-content-inner {
        padding: 0 16px;
        gap: 16px;
    }

    .hero-brand {
        min-height: 65px;
    }

    .hero-logo-image {
        height: 62px;
        transform: translate(-5px, 0px);
    }

    .hero-subtitle {
        font-size: 14px;
        line-height: 1.35;
        transform: translate(40px, 45px);
    }

    .hero-buttons {
        max-width: 100%;
    }

    .systems-section {
        padding: 40px 15px;
    }

    .services-section {
        padding: 40px 15px;
        padding-top: 0;
    }

    .news-section {
        padding: 40px 15px;
    }
}				