/* 폰트 */
@import url('../font/variable/pretendardvariable.css');

/* 기본 설정 */
:root {
    --tuva-green: #66A0A0;
    --tuva-dark: #333333;
    --tuva-light: #F8F9FA;
    --tuva-white: #FFFFFF;
}

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

body {
    font-family: 'Pretendard', sans-serif;
    line-height: 1.6;
    color: #333;
}

html {
    scroll-behavior: smooth;
}

/* 헤더 스타일 */
header {
    position: fixed;
    width: 100%;
    top: 0;
    background: white;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.logo {
    height: 40px;
}

.logo img {
    height: 40px;
    width: auto;
    object-fit: contain;
}

.main-nav {
    position: relative;
    display: flex;
    align-items: center;
    padding: 16px 0px;
    max-width: 1200px;
    margin: 0 auto;
}

/* 네비게이션 링크 스타일 */
.nav-links {
    display: flex;
    gap: 50px;
    margin-left: 50px;
    font-size: 1.1rem;
}

.nav-item {
    position: relative;
}

.nav-link {
    text-decoration: none;
    color: var(--tuva-dark);
    padding: 20px 0;
    transition: color 0.3s ease;
}

.nav-item.active .nav-link {
    color: var(--tuva-green);
    font-weight: 500;
}

/* 햄버거 메뉴 스타일 */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1100;
    margin-left: auto;
}

.hamburger span {
    width: 100%;
    height: 3px;
    background-color: var(--tuva-dark);
    transition: all 0.3s ease;
}

/* 서비스 링크 스타일 */
.header-service-link {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--tuva-white);
    text-decoration: none;
    margin-left: auto;
    padding: 8px 16px;
    border: none;
    border-radius: 4px;
    transition: all 0.3s ease;
    background-color: var(--tuva-green);
    justify-content: center;
}

.header-service-link:hover {
    background-color: var(--tuva-dark);
    color: var(--tuva-white);
}

.header-service-link svg {
    transition: transform 0.3s ease;
    color: var(--tuva-white);
}

.header-service-link:hover svg {
    transform: translate(2px, -2px);
    color: var(--tuva-white);
}

.mobile-service-link {
    display: none; /* 기본적으로 숨김 */
}

/* 드롭다운 메뉴 스타일 */
.dropdown-menu {
    position: fixed;
    top: 70px;
    left: 0;
    right: 0;
    width: 100%;
    background: white;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease, transform 0.4s cubic-bezier(0.215, 0.61, 0.355, 1);
    z-index: 1000;
    transform: translateY(-20px);
    pointer-events: none;
}

.dropdown-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 30px 10px;
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 40px;
}

/* active 클래스가 있을 때만 드롭다운 메뉴 표시 */
.nav-item.active .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

/* 드롭다운 배경 오버레이 */
.dropdown-backdrop {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
    z-index: 999;
    pointer-events: none;
}

.dropdown-backdrop.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

/* 푸터 스타일 */
.footer {
    background: var(--tuva-light);
    padding: 30px 0 20px;
}

.footer-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 로고와 메뉴를 가로로 배치하기 위한 스타일 */
.footer-top {
    display: flex;
    align-items: flex-start;
    gap: 200px;
}

.footer-logo {
    flex-shrink: 0;
    min-width: 120px;
}

.footer-logo img {
    height: 40px;
    width: auto;
}

.footer-columns {
    display: flex;
    flex: 1;
    gap: 10px;
    justify-content: space-between;
}

.footer-column {
    flex: 1;
}

.footer-column h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 20px;
    color: var(--tuva-green);
}

.footer-column ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-column li {
    margin-bottom: 10px;
}

.footer-column a {
    color: var(--tuva-dark);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.3s;
}

.footer-column a:hover {
    color: var(--tuva-green);
}

.footer-container {
    margin-bottom: 20px;
}

.footer-info {
    margin-bottom: 10px;
    margin-top: 20px;
}

.footer-info p {
    font-size: 14px;
    color: #666;
    margin-bottom: 5px;
}

.footer-copyright-row {
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-copyright {
    color: #888;
    font-size: 14px;
    margin-top: 10px;
}

.footer-links {
    display: flex;
    gap: 20px;
    margin-top: 10px;
}

.footer-links a {
    color: #888;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--tuva-green);
}

@media (max-width: 768px) {
    .footer-top {
        flex-direction: column;
        gap: 30px;
    }
    
    .footer-logo {
        text-align: left;
    }
    
    .footer-columns {
        flex-wrap: wrap;
    }
    
    .footer-column {
        flex-basis: 45%;
    }
    
    .footer {
        padding: 40px 0 20px;
    }

    .footer-copyright-row {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .footer-links {
        justify-content: center;
    }
}

/* 메뉴 섹션 스타일 */
.menu-section {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.menu-section h3 {
    font-size: 21px;
    font-weight: 500;
    margin-bottom: 8px;
}

.menu-section p {
    font-size: 16px;
    line-height: 1.6;
    color: #666;
    margin-bottom: 16px;
}

.menu-section a {
    display: block;
    color: var(--tuva-dark);
    text-decoration: none;
    font-size: 16px;
    transition: color 0.3s ease;
}

.menu-section a:last-child {
    margin-bottom: 0;
}

.menu-section a:hover {
    color: var(--tuva-green);
}

.menu-section h4 {
    font-size: 16px;
    font-weight: 600;
    color: var(--tuva-dark);
    margin-bottom: 16px;
}

.menu-section .menu-links {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.menu-section .menu-links a {
    color: #666;
    text-decoration: none;
    transition: color 0.3s ease;
    padding: 8px;
}

.menu-section .menu-links a:hover {
    color: var(--tuva-green);
}

.menu-section:nth-child(2) {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 40px;
}

.menu-links {
    display: flex;
    flex-direction: column;
}

.menu-links h4 {
    font-size: 18px;
    font-weight: 600;
    color: var(--tuva-dark);
    margin-bottom: 0px;
    border-bottom: 1px solid var(--tuva-green);
    padding-bottom: 8px;
    display: inline-block;
}

.menu-column {
    display: flex;
    flex-direction: column;
}

.menu-column a {
    color: #666;
    text-decoration: none;
    transition: color 0.3s ease;
}

.menu-column a:hover {
    color: var(--tuva-green);
}

/* 외부 링크 스타일 */
.external-link {
    display: flex !important;
    align-items: center;
    transition: all 0.3s ease !important;
    margin-top: auto;
}

.external-link svg {
    transition: transform 0.3s ease;
    color: #666;
}

.external-link:hover {
    color: var(--tuva-green) !important;
}

.external-link:hover svg {
    transform: translate(2px, -2px);
    color: var(--tuva-green);
}

/* 모바일 스타일 */
@media (max-width: 768px) {
    /* 햄버거 메뉴 표시 */
    .hamburger {
        display: flex;
    }

    .menu-section:nth-child(1) {
        display: none;
    }

    /* 햄버거 메뉴 활성화 시 스타일 */
    .hamburger.active span:first-child {
        transform: rotate(45deg) translate(6px, 6px);
        transition: transform 0.3s ease;
    }

    .hamburger.active span:nth-child(2) {
        opacity: 0;
        transition: opacity 0.2s ease;
    }

    .hamburger.active span:last-child {
        transform: rotate(-45deg) translate(6px, -6px);
        transition: transform 0.3s ease;
    }

    /* 네비게이션 링크 스타일 */
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 60%;
        height: 100vh;
        background-color: white;
        flex-direction: column;
        padding: 80px 30px 20px;
        z-index: 1000;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 10px;
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links a {
        font-size: 16px;
    }

    /* 메뉴 오픈 시 배경 오버레이 */
    .menu-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(0, 0, 0, 0.5);
        z-index: 999;
        opacity: 0;
    }

    .menu-overlay.active {
        display: block;
        opacity: 1;
    }

    /* 모바일에서 드롭다운 메뉴 애니메이션 */
    .dropdown-menu {
        position: static;
        box-shadow: none;
        max-height: 0;
        overflow: hidden;
        opacity: 0;
        visibility: hidden;
    }

    .nav-item.active .dropdown-menu {
        max-height: 1000px;
        opacity: 1;
        visibility: visible;
    }

    /* 서비스 링크 모바일 스타일 */
    .desktop-service-link {
        display: none !important;
    }
    
    .mobile-service-link {
        display: flex;
        margin: 0px auto 10px;
        width: 100%;
        justify-content: center;
        background-color: var(--tuva-green);
        color: var(--tuva-white);
        border: none;
        padding: 16px;
        position: relative;
        text-decoration: none;
    }
    
    .mobile-service-link svg {
        color: var(--tuva-white);
    }

    .header-service-link {
        position: relative;
        bottom: auto;
        right: auto;
        margin: 20px auto 0;
        width: 100%;
        justify-content: center;
        background-color: var(--tuva-green);
        color: var(--tuva-white);
        border: none;
        padding: 16px;
        z-index: 1001;
        display: none;
        text-decoration: none;
    }

    /* 메뉴가 열렸을 때만 표시 */
    .nav-links.active ~ .header-service-link {
        display: flex;
    }
    
    /* 메뉴 섹션 모바일 스타일 */
    .menu-section:nth-child(2) {
        grid-template-columns: 1fr;
        gap: 24px;
    }
}

/* 히어로 섹션 */
.hero {
    position: relative;
    height: 100vh;
    width: 100%;
    overflow: hidden;
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)),
                url('../images/hero-bg.png') no-repeat center center;
    background-size: cover;
    display: flex;
    align-items: flex-end;
    padding-bottom: 100px;
}

.hero-content {
    max-width: 800px;
    margin-left: 190px;
    color: #fff;
    bottom: 100px;
}

.hero-title {
    font-size: 64px;
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 24px;
}

.hero-description {
    font-size: 18px;
    line-height: 1.6;
    margin-bottom: 32px;
    max-width: 600px;
}

.hero-button {
    display: inline-block;
    padding: 12px 24px;
    background: transparent;
    color: #fff;
    text-decoration: none;
    border: 1px solid #fff;
    font-size: 16px;
    transition: all 0.3s ease;
}

.hero-button:hover {
    background: #fff;
    color: #000;
}

/* 컨텐츠 카드 섹션 */
.content-cards {
    padding: 80px 0;
    overflow-x: auto;
    white-space: nowrap;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
}

.content-cards::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
}

.card {
    display: inline-block;
    width: 400px;
    margin: 0 16px;
    white-space: normal;
    vertical-align: top;
}

.card-content {
    padding: 32px;
    border-radius: 8px;
}

.card h2 {
    font-size: 2rem;
    margin-bottom: 16px;
}

.learn-more {
    display: inline-block;
    margin-top: 24px;
    color: #333;
    text-decoration: none;
    font-weight: 600;
}

/* 뉴스레터 섹션 */
.newsletter {
    background: var(--tuva-green);
    color: var(--tuva-green);
    padding: 64px 48px;
    text-align: center;
}

.subscribe-form {
    display: flex;
    gap: 16px;
    max-width: 500px;
    margin: 32px auto 0;
}

.subscribe-form input {
    flex: 1;
    padding: 12px 16px;
    border: none;
    border-radius: 4px;
}

.subscribe-form button {
    padding: 12px 24px;
    background: var(--tuva-white);
    color: var(--tuva-green);
    border: none;
    border-radius: 4px;
    font-weight: 600;
    cursor: pointer;
}

/* 반응형 디자인 - 콘텐츠 관련 */
@media (max-width: 768px) {
    /* 히어로 섹션 */
    .hero-content {
        margin-left: 24px;
        margin-right: 24px;
    }

    .hero-title {
        font-size: 40px;
    }

    .hero-description {
        font-size: 16px;
    }

    /* 기타 콘텐츠 */
    .stats {
        grid-template-columns: 1fr;
    }

    .card {
        width: 300px;
    }

    .main-nav {
        padding: 18px;
    }

    .content-cards {
        padding: 24px;
    }

    .subscribe-form {
        flex-direction: column;
    }

    /* 드롭다운 콘텐츠 */
    .dropdown-content {
        grid-template-columns: 1fr;
        gap: 15px;
        padding: 15px 2px;
    }
}

.what-we-do, .careers, .our-firm {
    padding: 80px 0%;
    position: relative;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.section-header {
    margin-bottom: 48px;
}

.section-header h3 {
    font-size: 21px;
    font-weight: 600;
    margin-bottom: 10px;
    letter-spacing: 1px;
    color:var(--tuva-green);
}

.section-header h2 {
    font-size: 48px;
    font-weight: 600;
    line-height: 1.2;
    color:var(--tuva-green);
}

.section-header p {
    font-size: 18px;
    line-height: 1.6;
    max-width: 1200px;
    margin-top: 24px;
    color: var(--tuva-dark);
}

@media (max-width: 768px) {
    .what-we-do, .careers, .our-firm {
        padding: 40px 24px;
    }

    .section-header h2 {
        font-size: 32px;
    }
}

.cards-container {
    display: flex;
    gap: 24px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.cards-container::-webkit-scrollbar {
    display: none;
}

.service-card {
    flex: 0 0 auto;
    width: calc(33.333% - 16px);
    min-width: 250px;
    scroll-snap-align: start;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 20px;
}

.service-card img {
    width: 100%;
    aspect-ratio: 4/3;  /* 4:3 비율 설정 */
    object-fit: cover;
    margin-bottom: 24px;
}

.service-card h3 {
    font-size: 24px;
    font-weight: 500;
    margin-bottom: 16px;
    color: var(--tuva-green);
}

.service-card p {
    font-size: 16px;
    line-height: 1.6;
    color: #666;
    margin-bottom: auto;
}

/* 더 알아보기 링크 스타일 */
.more-link {
    display: inline-block;
    background-color: var(--tuva-white);
    color: var(--tuva-green);
    padding: 8px 16px;
    border-radius: 4px;
    border: 1px solid var(--tuva-green);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    margin-top: 15px;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.more-link:hover {
    transform: translateY(-2px);
}

.slider-controls {
    position: absolute;
    right: 0px;
    bottom: 0;
    display: flex;
    gap: 16px;
    z-index: 10;
}

.slider-controls button {
    width: 40px;
    height: 40px;
    border: 1px solid var(--tuva-green);
    background: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    color: var(--tuva-green);
}

.slider-controls button:hover {
    background: #FFF;
    color: var(--tuva-green);
}

/* 초기 상태에서 이전 버튼 비활성화 */
.slider-controls .prev {
    opacity: 0.5;
}

@media (max-width: 768px) {
    .slider-controls {
        right: 24px;
    }
}
.careers-gallery {
    margin-bottom: 60px;
}

.gallery-grid {
    max-width: 100%;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    height: 100vh;
}

.gallery-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-img:first-child {
    grid-row: span 2;
}

/* 통계 아이템 스타일 및 애니메이션 */
.careers-stats {
    max-width: 1200px;
    margin: 60px auto 0;
    padding: 0 120px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    margin-bottom: 60px;
}

.careers-stats .stat-item {
    text-align: left;
}

.careers-stats .stat-number {
    font-size: 48px;
    font-weight: 600;
    display: block;
    margin-bottom: 16px;
    color:var(--tuva-green);
}

.careers-stats .stat-item p {
    font-size: 16px;
    line-height: 1.6;
}

.careers-links {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 120px;
    display: flex;
    gap: 16px;
}

@media (max-width: 768px) {
    .gallery-grid {
        padding: 0 24px;
        height: auto;
        grid-template-columns: 1fr;
    }

    .careers-stats {
        padding: 0 24px;
        grid-template-columns: 1fr;
    }
}

.firm-cards {
    display: flex;
    flex-direction: column;
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.firm-card {
    display: flex;
    flex-direction: row;
    background: #fff;
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
    height: 150px;
}

.firm-card img {
    width: 200px;
    aspect-ratio: 4/3; 
    object-fit: cover;
    flex-shrink: 0;
}

.firm-card .card-content {
    padding: 15px 0px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    flex: 1;
}

.firm-card h3 {
    font-size: 20px;
    font-weight: 600;
}

.firm-card p {
    font-size: 15px;
    line-height: 1.6;
    color: #666;
}

.firm-card .learn-more {
    color: var(--tuva-dark);
    text-decoration: none;
    font-weight: 500;
    margin-top: auto;
}

.firm-card .learn-more:hover {
    text-decoration: underline;
}

@media (max-width: 768px) {
    .firm-card {
        flex-direction: column;
        max-height: none; /* max-height 제거 */
        height: auto; /* 자동 높이 설정 */
        padding: 20px;
    }

    .firm-card img {
        width: 100%;
        height: auto;
    }
}

/* 모달 팝업 스타일 */
.legal-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.6);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.legal-modal.show {
    display: block;
    opacity: 1;
}

.legal-modal-content {
    background-color: var(--tuva-white);
    margin: 5% auto;
    padding: 40px;
    border-radius: 10px;
    width: 80%;
    max-width: 800px;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    transform: translateY(-20px);
    transition: transform 0.3s ease;
}

.legal-modal.show .legal-modal-content {
    transform: translateY(0);
}

.legal-close-button {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 28px;
    font-weight: bold;
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--tuva-dark);
    transition: color 0.3s ease;
}

.legal-close-button:hover {
    color: var(--tuva-green);
}

.legal-modal-content h2 {
    font-size: 28px;
    margin-bottom: 24px;
    color: var(--tuva-green);
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(0,0,0,0.1);
}

.legal-modal-content h3 {
    font-size: 20px;
    margin-top: 24px;
    margin-bottom: 16px;
    color: var(--tuva-dark);
}

.legal-modal-content p {
    margin-bottom: 16px;
    font-size: 16px;
    line-height: 1.6;
    color: #666;
}

.legal-modal-content ul {
    margin-bottom: 16px;
    padding-left: 24px;
}

.legal-modal-content li {
    margin-bottom: 8px;
    font-size: 16px;
    line-height: 1.6;
    color: #666;
}

.legal-modal-content table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 16px;
}

.legal-modal-content th, 
.legal-modal-content td {
    border: 1px solid #ddd;
    padding: 12px;
    text-align: left;
}

.legal-modal-content th {
    background-color: var(--tuva-light);
    font-weight: 600;
}

/* 모바일 대응 */
@media (max-width: 768px) {
    .legal-modal-content {
        width: 90%;
        padding: 30px 20px;
        margin: 10% auto;
    }
    
    .legal-modal-content h2 {
        font-size: 24px;
    }
    
    .legal-modal-content h3 {
        font-size: 18px;
    }
    
    .legal-modal-content p,
    .legal-modal-content li {
        font-size: 15px;
    }
}

