/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Paperlogy', 'Pretendard', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
}

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

/* Header Styles */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 1000;
    transition: all 0.3s ease;
}

.header.scrolled {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

.navbar {
    padding: 1rem 0;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

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

.logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2563eb;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    margin: 0;
}

.nav-item {
    position: relative;
}

.nav-link {
    text-decoration: none;
    color: #374151;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    position: relative;
    /* 🎯 메뉴 정렬 해결책: 모든 메뉴를 같은 높이로 */
    height: 42px !important;
    display: flex !important;
    align-items: center !important;
    line-height: 1.2 !important;
}

.nav-link:hover,
.nav-link.active {
    color: #2563eb;
    background: rgba(37, 99, 235, 0.1);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    width: 0;
    height: 2px;
    background: #2563eb;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 80%;
}

/* Dropdown Menu Styles */
.nav-item.dropdown {
    position: relative;
    display: flex;
    align-items: center;
}

.dropdown-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    height: 42px !important; /* 다른 메뉴와 동일한 높이 */
}

.dropdown-toggle i {
    font-size: 0.75em;
    transition: transform 0.3s ease;
    line-height: 1 !important;
    margin: 0 !important; /* 아이콘이 높이에 영향주지 않도록 */
}

.nav-item.dropdown:hover .dropdown-toggle i {
    transform: rotate(180deg);
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 8px); /* 조금 더 아래로 */
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(15px);
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    min-width: 320px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1001;
    border: 1px solid rgba(255, 255, 255, 0.2);
    list-style: none;
    padding: 0.5rem 0;
}

.nav-item.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.dropdown-menu li {
    margin: 0;
}

.dropdown-link {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.5rem;
    text-decoration: none;
    color: #374151;
    transition: all 0.3s ease;
    border-radius: 8px;
    margin: 0 0.5rem;
}

.dropdown-link:hover {
    background: rgba(37, 99, 235, 0.05);
    color: #2563eb;
    transform: translateX(5px);
}

.dropdown-link i {
    width: 20px;
    height: 20px;
    font-size: 1.1rem;
    color: #2563eb;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dropdown-link span {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.dropdown-link strong {
    font-weight: 600;
    font-size: 0.95rem;
    color: inherit;
}

.dropdown-link small {
    font-size: 0.8rem;
    color: #6b7280;
    line-height: 1.3;
}

.dropdown-link:hover small {
    color: #4b5563;
}

/* Mobile Menu */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 8px;
}

.bar {
    width: 25px;
    height: 3px;
    background-color: #374151;
    margin: 3px 0;
    transition: 0.3s;
    border-radius: 2px;
}

/* Hero Section */
.hero-section {
    position: relative;
    height: 100vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.video-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    background: linear-gradient(
        135deg,
        #1e3a8a 0%,
        #1e40af 25%,
        #2563eb 50%,
        #3b82f6 75%,
        #60a5fa 100%
    );
}

.video-background video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translate(-50%, -50%);
    object-fit: cover;
    object-position: center;
    z-index: 1;
}

.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        45deg,
        rgba(30, 58, 138, 0.3) 0%,
        rgba(37, 99, 235, 0.2) 50%,
        rgba(16, 185, 129, 0.3) 100%
    );
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 3;
    text-align: center;
    color: white;
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    font-family: 'Paperlogy', 'Pretendard', sans-serif;
}

.title-line-1,
.title-line-2 {
    display: block;
    animation: fadeInUp 1s ease-out;
}

.title-line-2 {
    animation-delay: 0.3s;
    opacity: 0;
    animation-fill-mode: forwards;
}

.hero-subtitle {
    font-size: clamp(1.1rem, 2.5vw, 1.5rem);
    margin-bottom: 2.5rem;
    opacity: 0.95;
    animation: fadeInUp 1s ease-out 0.6s;
    animation-fill-mode: forwards;
    opacity: 0;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeInUp 1s ease-out 0.9s;
    animation-fill-mode: forwards;
    opacity: 0;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 14px 32px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.btn-primary {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: white;
    box-shadow: 0 4px 20px rgba(37, 99, 235, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(37, 99, 235, 0.4);
}

.btn-outline {
    background: transparent;
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
}

.btn-outline:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: white;
    transform: translateY(-2px);
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    animation: bounce 2s infinite;
}

.scroll-icon {
    color: white;
    font-size: 1.5rem;
    opacity: 0.8;
}

/* About Section */
.about-section {
    padding: 100px 0;
    background: #f8fafc;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-header h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 1rem;
}

.section-header p {
    font-size: 1.2rem;
    color: #6b7280;
    max-width: 600px;
    margin: 0 auto;
}

.about-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 60px;
}

.about-card {
    background: white;
    padding: 2.5rem;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.about-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, #2563eb, #10b981);
}

.about-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
}

.card-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
}

.about-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 1rem;
}

.about-card p {
    color: #6b7280;
    line-height: 1.6;
}

/* Features Section */
.features-section {
    padding: 100px 0;
    background: white;
}

.features-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.features-text h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 1.5rem;
}

.features-text p {
    font-size: 1.2rem;
    color: #6b7280;
    margin-bottom: 2rem;
}

.feature-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.feature-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.feature-icon {
    width: 24px;
    height: 24px;
    color: #10b981;
    font-size: 1.2rem;
    flex-shrink: 0;
    margin-top: 2px;
}

.feature-content h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.feature-content p {
    color: #6b7280;
    font-size: 0.95rem;
}

.features-image {
    text-align: center;
}

.features-image img {
    max-width: 100%;
    height: auto;
    border-radius: 20px;
}

/* Footer */
.footer {
    background: #1f2937;
    color: white;
    padding: 60px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h4 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: white;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 1rem;
}

.footer-logo img {
    height: 32px;
    width: auto;
    max-width: 100px;
    object-fit: contain;
}

.footer-logo span {
    font-size: 1.3rem;
    font-weight: 700;
    color: #60a5fa;
}

.footer-section p {
    color: #d1d5db;
    line-height: 1.6;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section ul li a {
    color: #d1d5db;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section ul li a:hover {
    color: #60a5fa;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #d1d5db;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background: #2563eb;
    color: white;
    transform: translateY(-2px);
}

.footer-bottom {
    border-top: 1px solid #374151;
    padding-top: 2rem;
    text-align: center;
}

.footer-bottom p {
    color: #9ca3af;
    font-size: 0.9rem;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    40% {
        transform: translateX(-50%) translateY(-10px);
    }
    60% {
        transform: translateX(-50%) translateY(-5px);
    }
}

/* Responsive Design */
@media (max-width: 1024px) {
    .features-content {
        grid-template-columns: 1fr;
        gap: 3rem;
        text-align: center;
    }
    
    .nav-menu {
        gap: 1.5rem;
    }
}

@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }
    
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(10px);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
        padding: 2rem 0;
        gap: 0;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-menu li {
        margin: 1rem 0;
    }
    
    /* 모바일 드롭다운 스타일 */
    .nav-item.dropdown {
        position: static;
    }
    
    .dropdown-menu {
        position: static;
        transform: none;
        background: rgba(37, 99, 235, 0.05);
        backdrop-filter: none;
        box-shadow: none;
        border: none;
        border-radius: 0;
        min-width: auto;
        width: 100%;
        margin: 0.5rem 0 0 0;
        padding: 0;
        opacity: 0;
        visibility: hidden;
        max-height: 0;
        overflow: hidden;
        transition: all 0.3s ease;
    }
    
    .nav-item.dropdown.active .dropdown-menu {
        opacity: 1;
        visibility: visible;
        max-height: 300px;
    }
    
    .dropdown-link {
        padding: 0.75rem 2rem;
        margin: 0;
        border-radius: 0;
        font-size: 0.9rem;
    }
    
    .dropdown-link:hover {
        background: rgba(37, 99, 235, 0.1);
        transform: none;
    }
    
    .dropdown-toggle {
        justify-content: center;
        cursor: pointer;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .btn {
        width: 100%;
        max-width: 280px;
    }
    
    .about-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .about-card {
        padding: 2rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .nav-container {
        padding: 0 15px;
    }
    
    .hero-content {
        padding: 0 15px;
    }
    
    .about-card {
        padding: 1.5rem;
    }
    
    .btn {
        padding: 12px 24px;
        font-size: 0.9rem;
    }
}

/* Video Optimization for Performance */
@media (prefers-reduced-motion: reduce) {
    .video-background video {
        display: none;
    }
    
    .video-background {
        background: linear-gradient(
            45deg,
            rgba(37, 99, 235, 0.8) 0%,
            rgba(59, 130, 246, 0.7) 50%,
            rgba(16, 185, 129, 0.8) 100%
        );
    }
}

/* Performance optimizations for mobile */
@media (max-width: 768px) {
    .video-background video {
        transform: scale(1.1);
        object-position: 20% center;
    }
}

/* High DPI displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .logo-img {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
}
