/* =========================================================================
   KMFactory Premium Styling
   ========================================================================= */

:root {
    --bg-main: #060913;
    --bg-secondary: #0c1222;
    --primary: #00f0ff;
    --primary-glow: rgba(0, 240, 255, 0.4);
    --secondary: #7000ff;
    --text-main: #ffffff;
    --text-muted: #a0aabf;
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Noto Sans KR', sans-serif;
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

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

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, .logo {
    font-family: var(--font-heading);
}

a {
    text-decoration: none;
}

/* Typography Enhancements */
.gradient-text {
    background: linear-gradient(90deg, var(--primary), #b356ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

/* Glassmorphism Utilities */
.glass-nav {
    background: rgba(6, 9, 19, 0.7);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--glass-border);
}

.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 2.5rem;
}

/* Nav */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    transition: var(--transition);
}

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

.logo {
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: -0.5px;
}
.logo-km { color: var(--primary); }
.logo-factory { color: #fff; }

.nav-links a {
    color: var(--text-main);
    margin-left: 2rem;
    font-size: 1rem;
    font-weight: 500;
    transition: var(--transition);
}

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

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.8rem 1.8rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    transition: var(--transition);
    cursor: pointer;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, #00a2ff 100%);
    color: #000 !important;
    box-shadow: 0 0 20px var(--primary-glow);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 30px var(--primary-glow);
}

.btn-secondary {
    background: transparent;
    color: #fff !important;
    border: 1px solid var(--glass-border);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.2);
}

/* Hero Section */
.hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-image: url('../img/hero_bg.png');
    background-size: cover;
    background-position: center;
    text-align: center;
    padding: 0 2rem;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(6, 9, 19, 0.3) 0%, rgba(6, 9, 19, 1) 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
}

.hero-title {
    font-size: 4.5rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    font-weight: 800;
    letter-spacing: -1px;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
    font-weight: 300;
}

.hero-cta {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.scroll-indicator {
    position: absolute;
    bottom: 40px;
    z-index: 2;
    color: var(--text-muted);
    animation: bounce 2s infinite;
}

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

/* Common Section Styles */
.section-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 8rem 2rem;
}

.section-header {
    text-align: center;
    margin-bottom: 5rem;
}

.section-title {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.title-underline {
    width: 60px;
    height: 4px;
    background: var(--primary);
    margin: 0 auto 1.5rem;
    border-radius: 2px;
    box-shadow: 0 0 10px var(--primary-glow);
}

.section-desc {
    color: var(--text-muted);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

/* Services */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

.service-card {
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: radial-gradient(circle at 50% 0%, rgba(0, 240, 255, 0.1), transparent 70%);
    opacity: 0;
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-10px);
    border-color: rgba(0, 240, 255, 0.3);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.service-card:hover::before {
    opacity: 1;
}

.service-icon {
    width: 64px;
    height: 64px;
    background: rgba(0, 240, 255, 0.1);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    color: var(--primary);
}

.service-icon svg {
    width: 32px;
    height: 32px;
}

.service-card h3 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
}

.service-card p {
    color: var(--text-muted);
}

/* Contact Section */
.contact-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 4rem;
    position: relative;
    overflow: hidden;
}

.contact-info {
    position: relative;
    z-index: 2;
    max-width: 500px;
}

.contact-info .section-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.contact-desc {
    color: var(--text-muted);
    margin-bottom: 2.5rem;
    font-size: 1.1rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.icon-wrap {
    width: 50px;
    height: 50px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #000;
    box-shadow: 0 0 20px var(--primary-glow);
}

.item-text h4 {
    font-size: 0.9rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.2rem;
}

.email-link {
    font-size: 1.5rem;
    color: #fff;
    font-weight: 600;
    transition: var(--transition);
}

.email-link:hover {
    color: var(--primary);
}

/* Visuals inside Contact */
.contact-visual {
    position: absolute;
    right: 0;
    top: 0;
    width: 50%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.glowing-orb {
    position: absolute;
    top: 50%;
    right: 10%;
    transform: translateY(-50%);
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(0, 240, 255, 0.4) 0%, transparent 70%);
    border-radius: 50%;
    filter: blur(40px);
}

.orb-2 {
    top: 20%;
    right: -10%;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(112, 0, 255, 0.3) 0%, transparent 70%);
}

/* Footer */
footer {
    border-top: 1px solid var(--glass-border);
    padding: 2rem 0;
    margin-top: 4rem;
}

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

.footer-brand {
    font-size: 1.5rem;
    font-weight: 800;
}

.copyright {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    .hero-title {
        font-size: 2.8rem;
    }
    .contact-card {
        flex-direction: column;
        padding: 2rem;
        text-align: center;
    }
    .contact-item {
        flex-direction: column;
        justify-content: center;
        text-align: center;
    }
    .email-link {
        font-size: 1.2rem;
    }
}
