@import url('https://cdn.jsdelivr.net/gh/orioncactus/pretendard/dist/web/static/pretendard.css');

/* --- 🎨 테마 및 글로벌 변수 --- */
:root {
    --bg-page: #F8FAFC; 
    --bg-header: rgba(248, 250, 252, 0.7);
    --text-main: #0F172A; 
    --text-muted: #64748B; 
    --border-color: rgba(15, 23, 42, 0.08);
    --accent: #3B82F6; 
    --btn-bg: rgba(255, 255, 255, 0.9);
    --tooltip-bg: #1E293B;
    --tooltip-text: #FFFFFF;
    --blob-1: rgba(59, 130, 246, 0.25);
    --blob-2: rgba(139, 92, 246, 0.25);
}

[data-theme="dark"] {
    --bg-page: #0B0F19; 
    --bg-header: rgba(11, 15, 25, 0.7);
    --text-main: #F8FAFC; 
    --text-muted: #94A3B8; 
    --border-color: rgba(255, 255, 255, 0.08);
    --accent: #60A5FA; 
    --btn-bg: rgba(30, 41, 59, 0.8);
    --tooltip-bg: #FFFFFF;
    --tooltip-text: #0F172A;
    --blob-1: rgba(59, 130, 246, 0.15);
    --blob-2: rgba(139, 92, 246, 0.15);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Pretendard', sans-serif; background-color: var(--bg-page); color: var(--text-main); transition: background-color 0.4s ease, color 0.4s ease; overflow-x: hidden; }
.hidden { display: none !important; }
@media (max-width: 768px) { .pc-only { display: none !important; } }
@media (min-width: 769px) { .mobile-only { display: none !important; } }

/* --- 🌟 헤더 --- */
.header-wrapper { 
    width: 100%; position: fixed; top: 0; left: 0; z-index: 1000;
    background: var(--bg-header); backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px);
    border-bottom: 1px solid var(--border-color); transition: all 0.3s ease;
}
.header-inner { max-width: 1200px; margin: 0 auto; padding: 14px 24px; display: flex; justify-content: space-between; align-items: center; }

.header-logo-link { display: flex; align-items: center; height: 48px; transition: transform 0.2s; }
.header-logo-link:hover { transform: scale(1.02); }
.header-logo { height: 100%; width: auto; object-fit: contain; }

[data-theme="light"] .logo-for-dark { display: none; }
[data-theme="dark"] .logo-for-light { display: none; }

@media (max-width: 768px) { .header-logo-link { height: 36px; } }

.header-utils { display: flex; gap: 12px; align-items: center; }
.hub-btn { display: flex; align-items: center; gap: 8px; background: var(--btn-bg); border: 1px solid var(--border-color); text-decoration: none; color: var(--text-main); font-weight: 700; font-size: 0.9rem; padding: 8px 16px; border-radius: 24px; transition: 0.2s; box-shadow: 0 2px 8px rgba(0,0,0,0.03); }
.hub-btn:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-1px); }
.hub-icon { width: 18px; height: 18px; object-fit: contain; }

.icon-btn { background: none; border: none; cursor: pointer; color: var(--text-muted); width: 40px; height: 40px; border-radius: 50%; display: flex; justify-content: center; align-items: center; transition: 0.2s; }
.icon-btn:hover { background: var(--border-color); color: var(--text-main); }

.hub-btn-container { position: relative; display: flex; align-items: center; }
.hub-btn-container::before, .hub-btn-container::after { position: absolute; opacity: 0; visibility: hidden; transition: 0.3s; pointer-events: none; z-index: 1001; }
.hub-btn-container::before { content: attr(data-tooltip); top: calc(100% + 12px); right: 0; background: var(--tooltip-bg); color: var(--tooltip-text); padding: 10px 16px; border-radius: 8px; font-size: 0.85rem; font-weight: 700; white-space: nowrap; box-shadow: 0 10px 25px rgba(0,0,0,0.2); transform: translateY(-10px); }
.hub-btn-container::after { content: ""; top: calc(100% + 4px); right: 24px; border-width: 8px; border-style: solid; border-color: transparent transparent var(--tooltip-bg) transparent; transform: translateY(-10px); }
.hub-btn-container:hover::before, .hub-btn-container:hover::after { opacity: 1; visibility: visible; transform: translateY(0); }

/* --- 🌟 Hero 섹션 --- */
.hero-section {
    position: relative; width: 100vw; min-height: 100vh; 
    display: flex; align-items: center; justify-content: center; 
    overflow: hidden; padding-top: 60px;
}

.ambient-blobs { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; overflow: hidden; }
.blob { position: absolute; border-radius: 50%; filter: blur(80px); animation: float 10s infinite alternate ease-in-out; }
.blob-1 { top: 10%; left: 20%; width: 500px; height: 500px; background: var(--blob-1); }
.blob-2 { bottom: 10%; right: 10%; width: 600px; height: 600px; background: var(--blob-2); animation-delay: -5s; }
@keyframes float { 0% { transform: translate(0, 0) scale(1); } 100% { transform: translate(50px, 50px) scale(1.1); } }

.hero-container {
    position: relative; z-index: 2; width: 100%; max-width: 1200px;
    display: flex; align-items: center; justify-content: space-between;
    padding: 0 24px; gap: 40px;
}

.hero-text-area { flex: 1; max-width: 600px; animation: fadeUp 1s ease-out forwards; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }

.hero-title { font-size: 4.5rem; font-weight: 900; line-height: 1.1; letter-spacing: -0.03em; margin-bottom: 24px; color: var(--text-main); }
.hero-highlight { background: linear-gradient(to right, #3B82F6, #8B5CF6); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.hero-subtitle { font-size: 1.25rem; font-weight: 500; color: var(--text-muted); line-height: 1.6; margin-bottom: 40px; word-break: keep-all; }

.hero-cta {
    display: inline-flex; align-items: center;
    background: var(--text-main); color: var(--bg-page); border: none;
    padding: 16px 36px; font-size: 1.15rem; font-weight: 800; border-radius: 30px;
    cursor: pointer; transition: 0.3s; box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}
.hero-cta:hover { transform: translateY(-3px); box-shadow: 0 15px 40px rgba(0,0,0,0.25); background: var(--accent); color: #fff;}

.hero-visual-area { flex: 1; display: flex; justify-content: center; align-items: center; perspective: 1000px; }
.floating-visual { width: 100%; max-width: 500px; height: auto; object-fit: contain; animation: subtleHover 4s infinite alternate ease-in-out; transition: transform 0.1s ease-out; }
@keyframes subtleHover { 0% { transform: translateY(0px); } 100% { transform: translateY(-20px); } }

@media (max-width: 900px) {
    .hero-container { flex-direction: column; text-align: center; justify-content: center; margin-top: 40px; }
    .hero-title { font-size: 3.2rem; }
    .hero-subtitle { font-size: 1.1rem; }
    .hero-visual-area { margin-top: 20px; }
    .floating-visual { max-width: 300px; }
    .blob { filter: blur(50px); }
}

/* --- 🌟 STEP 2: 쇼케이스 영역 (Bento Grid) --- */
.showcase-section {
    padding: 120px 24px;
    background: var(--bg-page);
    position: relative;
    z-index: 10;
    scroll-margin-top: 70px;
}

.showcase-container { max-width: 1200px; margin: 0 auto; }
.showcase-header { text-align: center; margin-bottom: 60px; }

.section-title { font-size: 2.5rem; font-weight: 900; color: var(--text-main); letter-spacing: -0.02em; margin-bottom: 12px; }
.section-subtitle { font-size: 1.1rem; color: var(--text-muted); font-weight: 500; word-break: keep-all; }

/* 💡 반응형 격자 레이아웃 최적화 */
.bento-grid {
    display: grid; grid-template-columns: repeat(3, 1fr); grid-template-rows: repeat(2, 320px); gap: 24px;
}
.card-jigsaw { grid-column: 1 / 3; grid-row: 1 / 2; }
.card-sliding { grid-column: 3 / 4; grid-row: 1 / 2; }
.card-rotate { grid-column: 1 / 2; grid-row: 2 / 3; }
.card-swap { grid-column: 2 / 4; grid-row: 2 / 3; }

/* 💡 PC창 반으로 줄였을 때(태블릿) - 완벽한 2x2 그리드로 변환 */
@media (max-width: 1024px) {
    .bento-grid { grid-template-columns: 1fr 1fr; grid-template-rows: auto auto auto; }
    .card-jigsaw { grid-column: 1 / -1; height: 320px; } /* Jigsaw 2칸 차지 */
    .card-sliding { grid-column: 1 / 2; grid-row: 2 / 3; height: 320px; } /* Sliding 1칸 */
    .card-rotate { grid-column: 2 / 3; grid-row: 2 / 3; height: 320px; } /* Rotate 1칸 */
    .card-swap { grid-column: 1 / -1; height: 320px; } /* Swap 2칸 차지 */
}

/* 💡 모바일 - 1열 배열 */
@media (max-width: 768px) {
    .bento-grid { grid-template-columns: 1fr; }
    .card-jigsaw, .card-sliding, .card-rotate, .card-swap { grid-column: 1 / -1; grid-row: auto; height: 280px; }
}

.bento-card {
    position: relative; display: block; text-decoration: none; border-radius: 32px; overflow: hidden;
    background: var(--btn-bg); border: 1px solid var(--border-color); box-shadow: 0 10px 30px rgba(0,0,0,0.03);
    transform-style: preserve-3d; transition: box-shadow 0.4s ease, border-color 0.4s ease; cursor: pointer;
}
.bento-card:hover { box-shadow: 0 20px 40px rgba(59, 130, 246, 0.15); border-color: rgba(59, 130, 246, 0.3); }

.bento-media { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 1; }
.bento-thumb, .bento-video {
    width: 100%; height: 100%; object-fit: cover; position: absolute; top: 0; left: 0;
    transition: opacity 0.5s ease, transform 0.5s ease;
}
.bento-video { opacity: 0; }
.bento-card:hover .bento-thumb { opacity: 0; }
.bento-card:hover .bento-video { opacity: 1; transform: scale(1.05); }

.bento-content {
    position: absolute; bottom: 0; left: 0; width: 100%; padding: 40px 30px 30px 30px; z-index: 10;
    background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, transparent 100%);
    display: flex; justify-content: space-between; align-items: flex-end; transform: translateZ(30px);
}

/* 💡 트렌디한 타이틀 아이콘 적용 */
.bento-text h3 { 
    display: flex; align-items: center; gap: 8px;
    color: #ffffff; font-size: 1.5rem; font-weight: 800; margin-bottom: 6px; letter-spacing: -0.02em; 
}
.bento-text h3 svg { width: 24px; height: 24px; stroke-width: 2.5; color: var(--accent); }
.bento-text p { color: rgba(255, 255, 255, 0.85); font-size: 1rem; font-weight: 500; margin: 0; word-break: keep-all; }

.bento-arrow {
    background: rgba(255, 255, 255, 0.2); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
    width: 48px; height: 48px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
    color: #fff; transition: 0.3s ease;
}
.bento-card:hover .bento-arrow { background: var(--accent); transform: translateX(5px); }

@media (max-width: 900px) {
    .bento-text h3 { font-size: 1.3rem; }
    .bento-text h3 svg { width: 20px; height: 20px; }
}

/* --- 🌟 STEP 3: How It Works & Footer --- */
.scroll-reveal { opacity: 0; transform: translateY(40px); transition: opacity 0.8s ease-out, transform 0.8s ease-out; }
.scroll-reveal.active { opacity: 1; transform: translateY(0); }

.hiw-section { padding: 100px 24px; background: var(--bg-page); position: relative; z-index: 10; }
.hiw-container { max-width: 1000px; margin: 0 auto; }
.hiw-steps { display: flex; align-items: center; justify-content: space-between; margin-top: 60px; }

.step-card {
    flex: 1; background: var(--btn-bg); border: 1px solid var(--border-color); padding: 40px 30px;
    border-radius: 24px; text-align: center; box-shadow: 0 10px 30px rgba(0,0,0,0.02); position: relative;
}

.step-number {
    position: absolute; top: -15px; left: -15px; width: 48px; height: 48px; background: var(--text-main);
    color: var(--bg-page); font-size: 1.1rem; font-weight: 900; display: flex; align-items: center;
    justify-content: center; border-radius: 50%; box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.step-icon {
    width: 64px; height: 64px; margin: 0 auto 20px auto; background: rgba(59, 130, 246, 0.1);
    color: var(--accent); display: flex; align-items: center; justify-content: center; border-radius: 20px;
}
.step-icon svg { width: 32px; height: 32px; }

.step-title { font-size: 1.5rem; font-weight: 800; color: var(--text-main); margin-bottom: 12px; }
.step-desc { font-size: 1rem; color: var(--text-muted); line-height: 1.6; word-break: keep-all; }

.step-line { width: 60px; height: 2px; background: var(--border-color); margin: 0 20px; flex-shrink: 0; }

@media (max-width: 800px) {
    .hiw-steps { flex-direction: column; gap: 30px; }
    .step-card { width: 100%; }
    .step-line { width: 2px; height: 40px; margin: 0; }
}

/* 💡 가이드 링크 배너 최적화 (세련된 아이콘 박스 적용) */
.guide-link-banner {
    display: flex; align-items: center; justify-content: space-between;
    background: var(--btn-bg); border: 1px solid var(--border-color); padding: 20px 32px; 
    border-radius: 20px; text-decoration: none; margin-top: 50px; 
    box-shadow: 0 10px 30px rgba(0,0,0,0.02); transition: 0.3s ease;
}
.guide-link-banner:hover { border-color: var(--accent); transform: translateY(-3px); box-shadow: 0 15px 40px rgba(59, 130, 246, 0.1); }
.guide-link-content { display: flex; align-items: center; gap: 20px; }

.guide-icon-wrap {
    width: 56px; height: 56px; background: rgba(59, 130, 246, 0.1); color: var(--accent);
    border-radius: 16px; display: flex; align-items: center; justify-content: center;
}
.guide-icon-wrap svg { width: 28px; height: 28px; stroke-width: 2; }

.guide-text { display: flex; flex-direction: column; gap: 4px; text-align: left; }
.guide-text strong { font-size: 1.15rem; font-weight: 800; color: var(--text-main); }
.guide-text span { font-size: 0.95rem; color: var(--text-muted); font-weight: 500; word-break: keep-all; }
.guide-arrow { color: var(--text-muted); transition: 0.3s; }
.guide-link-banner:hover .guide-arrow { color: var(--accent); transform: translateX(3px) translateY(-3px); }

@media (max-width: 600px) {
    .guide-link-banner { padding: 20px; flex-direction: column; text-align: center; gap: 16px; position: relative; }
    .guide-link-content { flex-direction: column; gap: 12px; }
    .guide-arrow { position: absolute; top: 24px; right: 24px; }
}

.final-cta-section {
    padding: 120px 24px; text-align: center; background: linear-gradient(180deg, var(--bg-page) 0%, rgba(59, 130, 246, 0.05) 100%);
    border-top: 1px solid var(--border-color);
}
.cta-title { font-size: 3.5rem; font-weight: 900; letter-spacing: -0.03em; color: var(--text-main); margin-bottom: 40px; }

@media (max-width: 768px) { .cta-title { font-size: 2.5rem; } }

/* 💡 푸터 로고 대폭 확대 및 텍스트 최적화 */
.footer { padding: 40px 24px; background: var(--bg-page); border-top: 1px solid var(--border-color); text-align: center; }
.footer-inner { max-width: 1200px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; gap: 8px; }

.footer-logo-wrap { height: 72px; margin-bottom: 4px; } /* 로고 크기 대폭 확대 */
.footer-logo { height: 100%; width: auto; object-fit: contain; filter: grayscale(100%) opacity(0.5); transition: 0.3s; }
.footer-logo:hover { filter: grayscale(0%) opacity(1); }

.footer-privacy-text { font-size: 0.85rem; color: var(--text-muted); font-weight: 500; margin-bottom: 8px; word-break: keep-all; }

.footer-bottom { display: flex; flex-direction: column; align-items: center; gap: 8px; margin-top: 8px; }
.footer-copyright { font-size: 0.8rem; color: var(--text-muted); }

.footer-links { display: flex; gap: 24px; }
.footer-links a { color: var(--text-muted); text-decoration: none; font-size: 0.8rem; font-weight: 600; }
.footer-links a:hover { color: var(--text-main); text-decoration: underline; }