:root {
    --primary-color: #007BFF;
    --secondary-color: #6C757D;
    --background-color: #FFFFFF;
    --text-color: #333333;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans KR', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    margin: 0;
    padding: 0;
    scroll-behavior: smooth; /* 스크롤 부드럽게 이동하는 CSS 속성 */
}

/* Header */
header {
    width: 100%;
    background: transparent;
    z-index: 1000;
    padding: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
    position: fixed;
    top: 0;
    left: 0;
    transition: background-color 0.3s ease;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 60px;
}

.nav-links {
    display: flex;
    margin-left: auto;  /* 오른쪽 정렬을 위해 추가 */
    gap: 30px;         /* 메뉴 항목 간 간격 */
    list-style: none;
    align-items: center;
}

.nav-links a {
    color: white;
    text-decoration: none;
    font-size: 1.1rem;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: var(--primary-color);
}

.language-selector a {
    color: white;
    text-decoration: none;
    transition: color 0.3s ease;
}

.language-selector a:hover {
    color: var(--primary-color);
}

/* Hero Section */
.hero {
    height: 100vh;
    background: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), url('/images/main.png');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 2rem;
}

.hero-dots {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
}

.hero-dots span {
    width: 10px;
    height: 10px;
    background: white;
    border-radius: 50%;
}

/* Features Section */
.features {
    padding: 60px 0;
    max-width: 1200px;
    margin: 0 auto;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    padding: 0 20px;
}

.feature-item {
    text-align: center;    
}

.feature-item img {
    width: 100%;
    height: auto;
    margin-bottom: 1rem;
    /* border-radius: 5%; */
}

.feature-item h3 {
    margin-bottom: 1rem;
}

.more-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
}

/* News Section */
.news {
    padding: 5rem 5%;
    background: #f8f9fa;
    text-align: center;
}

.news-categories {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    max-width: 1200px;
    margin: 2rem auto 0;
}

.news-category {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

/* Location Section */
.location {
    padding: 5rem 5%;
    text-align: center;
}

.location-tabs {
    margin: 2rem 0;
}

.tab {
    padding: 0.5rem 2rem;
    border: none;
    background: none;
    cursor: pointer;
    font-size: 1.1rem;
}

.tab.active {
    color: var(--primary-color);
    border-bottom: 2px solid var(--primary-color);
}

.location-map {
    height: 400px;
    background: #eee;
    margin: 0 auto;
    max-width: 1200px;
}

/* Footer */
footer {
    background: #333;
    color: white;
    padding: 3rem 5%;
    padding-bottom: 1rem;
}

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

.company-info {
    margin-bottom: 2rem;
}

.copyright {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
}


@media (max-width: 768px) {
    .slider-title {
        font-size: 2rem;
        width: 90%;
        word-break: keep-all;
    }

    nav {
        justify-content: space-between;
        padding: 10px 20px;
    }    

    .nav-links {
        display: none;
        position: fixed;
        top: 116px;
        left: 0;
        width: 100%;
        height: auto;
        background-color: rgba(255, 255, 255, 0.95);
        padding: 20px 0;
        text-align: center;
        margin-left: 0;
        box-shadow: 0 2px 5px rgba(0,0,0,0.1);
        z-index: 1000;
    }

    .nav-links.active {
        display: flex;
        flex-direction: column;
    }

    .nav-links li {
        margin: 15px 0;
    }

    .nav-links a {
        color: #000;
        font-size: 1.2rem;
        padding: 10px 20px;
        display: block;
        width: 100%;
    }

    .nav-links a:hover {
        background-color: rgba(0,0,0,0.05);
    }

    .hamburger {
        display: block;
        cursor: pointer;
        z-index: 1001;
        padding: 10px;
    }

    .hamburger-line {
        width: 25px;
        height: 3px;
        background-color: #fff;
        margin: 5px 0;
        transition: 0.3s;
        border-radius: 3px;
    }

    header.scrolled .hamburger-line {
        background-color: #000;
    }

    .hamburger.active .hamburger-line:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .hamburger.active .hamburger-line:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active .hamburger-line:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }

    /* 푸터 조정 */
    .footer-content {
        flex-direction: column;
        text-align: center;
    }

    .footer-content > div {
        width: 100% !important;
        float: none !important;
        margin-bottom: 20px;
    }

    .company-info p {
        font-size: 0.9rem;
    }
    
    .carousel-item {
        height: 100vh !important; /* 모바일에서도 전체 화면 강제로 유지 */
    }
    
    .carousel-item video {
        height: 100vh !important; 
        object-fit: cover !important; 
    }
    .background-video {
        min-width: 100% !important;
        min-height: 100% !important;
        object-fit: cover !important;
    }


    /* 캐러셀 컨트롤 버튼 위치 조정 */
    .carousel-control-prev,
    .carousel-control-next {
        top: calc(50% - 70px); /* 헤더 높이(약 70px)의 절반만큼 위로 조정 */
        transform: translateY(-50%);
        opacity: 0.8;
        transition: opacity 0.3s ease;
    }
    
    .carousel-control-prev:hover,
    .carousel-control-next:hover {
        opacity: 1;
    }
    
    .carousel-control-prev-icon,
    .carousel-control-next-icon {
        width: 40px;
        height: 40px;
    }

    .floating-contact {
        bottom: 20px;
        right: 20px;
    }

    .floating-contact a {
        width: 50px;
        height: 50px;
    }

    .floating-contact i {
        font-size: 20px;
    }
}

/* Carousel Item 설정 */
.carousel-item {
    position: relative;
    overflow: hidden;
    height: 90vh; /* 화면 전체 높이로 설정 */
}

/* 동영상이 부모 크기 전체를 덮도록 설정 */
.background-video {
    position: absolute;
    top: 50%;
    left: 50%;
    width: auto;
    height: auto;
    min-width: 100%;
    min-height: 100%;
    transform: translate(-50%, -50%);
    object-fit: cover;
    z-index: -1; /* 뒤로 보내기 */
}