/* ═══════════════════════════════════════════════════════════
   無盡藏[무진장] 전문상담연구소 - Styles
   ═══════════════════════════════════════════════════════════ */

/* Root Variables */
:root {
    --primary-color: #FFD700;
    --bg-dark: #0f172a;
    --bg-darker: #020617;
    --bg-card: #1e293b;
    --text-primary: #f1f5f9;
    --text-secondary: #cbd5e1;
    --text-muted: #94a3b8;
    --accent-purple: #a78bfa;
    --accent-blue: #60a5fa;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.6);
    --border-radius: 12px;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Noto Sans KR', sans-serif;
    background: linear-gradient(135deg, var(--bg-darker) 0%, var(--bg-dark) 100%);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Google Translate Widget */
.translate-widget {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    background: var(--bg-card);
    padding: 8px 12px;
    border-radius: 8px;
    box-shadow: var(--shadow-lg);
}

.translate-widget .goog-te-gadget {
    font-family: 'Noto Sans KR', sans-serif !important;
}

.translate-widget .goog-te-combo {
    background: var(--bg-dark);
    border: 1px solid var(--primary-color);
    color: var(--text-primary);
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 14px;
}

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

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.navbar.scrolled {
    background: rgba(15, 23, 42, 0.98);
    box-shadow: var(--shadow-lg);
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--text-primary);
}

.dharma-wheel {
    flex-shrink: 0;
}

.logo-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.logo-main {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary-color);
    font-family: 'Noto Serif KR', serif;
}

.logo-sub {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: var(--text-secondary);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
    align-items: center;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
    padding: 8px 12px;
    border-radius: 6px;
}

.nav-link:hover {
    color: var(--primary-color);
    background: rgba(255, 215, 0, 0.1);
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 3px;
    transition: var(--transition);
}

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

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

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

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 100px 20px 80px;
    background: 
        radial-gradient(circle at 20% 50%, rgba(167, 139, 250, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(96, 165, 250, 0.15) 0%, transparent 50%),
        linear-gradient(135deg, var(--bg-darker) 0%, var(--bg-dark) 100%);
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 900;
    font-family: 'Noto Serif KR', serif;
    color: var(--primary-color);
    margin-bottom: 20px;
    line-height: 1.2;
    text-shadow: 0 4px 8px rgba(255, 215, 0, 0.3);
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.5rem);
    color: var(--text-secondary);
    margin-bottom: 40px;
    font-weight: 300;
    line-height: 1.8;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 15px 30px;
    border-radius: var(--border-radius);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    box-shadow: var(--shadow-md);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, #fbbf24 100%);
    color: var(--bg-darker);
}

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

.btn-secondary {
    background: var(--bg-card);
    color: var(--text-primary);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: var(--bg-darker);
    transform: translateY(-2px);
}

/* Section Styles */
section {
    padding: 80px 20px;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    font-family: 'Noto Serif KR', serif;
    color: var(--primary-color);
    text-align: center;
    margin-bottom: 15px;
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--text-secondary);
    text-align: center;
    margin-bottom: 50px;
}

/* Chatbot Section */
.chatbot-section {
    background: var(--bg-dark);
}

.chatbot-container {
    max-width: 900px;
    margin: 0 auto;
    background: var(--bg-card);
    border-radius: var(--border-radius);
    padding: 30px;
    box-shadow: var(--shadow-xl);
}

.chat-messages {
    min-height: 200px;
    max-height: 500px;
    overflow-y: auto;
    margin-bottom: 30px;
    padding: 20px;
    background: var(--bg-dark);
    border-radius: 8px;
}

.message {
    margin-bottom: 20px;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.bot-message .message-content {
    background: linear-gradient(135deg, #4c1d95 0%, #5b21b6 100%);
    padding: 15px 20px;
    border-radius: 12px;
    display: inline-block;
    max-width: 80%;
}

.user-message {
    text-align: right;
}

.user-message .message-content {
    background: var(--primary-color);
    color: var(--bg-darker);
    padding: 15px 20px;
    border-radius: 12px;
    display: inline-block;
    max-width: 80%;
    font-weight: 500;
}

.consultation-buttons {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.consult-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 20px 15px;
    background: var(--bg-dark);
    border: 2px solid transparent;
    border-radius: var(--border-radius);
    color: var(--text-primary);
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
}

.consult-btn i {
    font-size: 2rem;
    color: var(--primary-color);
}

.consult-btn span {
    font-weight: 700;
    font-size: 1.1rem;
}

.consult-btn small {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.consult-btn:hover {
    border-color: var(--primary-color);
    background: rgba(255, 215, 0, 0.1);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.reset-btn {
    width: 100%;
    padding: 15px;
    background: var(--bg-dark);
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    border-radius: var(--border-radius);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.reset-btn:hover {
    background: var(--primary-color);
    color: var(--bg-darker);
}

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

.service-card {
    background: var(--bg-card);
    padding: 40px 30px;
    border-radius: var(--border-radius);
    text-align: center;
    transition: var(--transition);
    border: 2px solid transparent;
}

.service-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.service-card h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.service-card p {
    color: var(--text-secondary);
    line-height: 1.6;
}

.service-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

/* Contact Section */
.contact-section {
    background: var(--bg-dark);
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.contact-card {
    background: var(--bg-card);
    padding: 30px;
    border-radius: var(--border-radius);
    text-align: center;
    border: 2px solid transparent;
    transition: var(--transition);
}

.contact-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.contact-card h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--text-primary);
}

.contact-card a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
}

.contact-card a:hover {
    text-decoration: underline;
}

.contact-card p {
    color: var(--text-secondary);
    margin: 5px 0;
}

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

.contact-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.contact-notice {
    background: var(--bg-card);
    padding: 25px;
    border-radius: var(--border-radius);
    text-align: center;
    border-left: 4px solid var(--primary-color);
}

.contact-notice i {
    color: var(--primary-color);
    font-size: 1.5rem;
    margin-right: 10px;
}

/* Footer */
.footer {
    background: var(--bg-darker);
    padding: 60px 20px 30px;
    text-align: center;
}

.footer-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 20px;
}

.footer-logo span {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary-color);
    font-family: 'Noto Serif KR', serif;
}

.footer-tagline {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: 30px;
    line-height: 1.8;
}

.footer-info {
    margin-bottom: 30px;
}

.footer-info p {
    color: var(--text-secondary);
    margin: 10px 0;
}

.footer-info i {
    color: var(--primary-color);
    margin-right: 8px;
}

.footer-notice {
    background: var(--bg-card);
    padding: 20px;
    border-radius: var(--border-radius);
    margin: 30px auto;
    max-width: 600px;
    border-left: 4px solid var(--primary-color);
}

.footer-notice i {
    color: var(--primary-color);
    margin-right: 8px;
}

.copyright {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 30px;
    padding-top: 30px;
    border-top: 1px solid var(--bg-card);
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    color: var(--bg-darker);
    border: none;
    border-radius: 50%;
    font-size: 1.25rem;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 999;
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

/* Dharma Wheel Animation */
#dharmaWheelGroup {
    transform-origin: 50% 50%;
    transform-box: fill-box;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .translate-widget {
        top: 10px;
        right: 10px;
        padding: 6px 8px;
    }

    .hamburger {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        top: 70px;
        right: -100%;
        width: 280px;
        height: calc(100vh - 70px);
        background: var(--bg-card);
        flex-direction: column;
        padding: 30px;
        gap: 20px;
        box-shadow: var(--shadow-xl);
        transition: var(--transition);
        align-items: flex-start;
        overflow-y: auto;
    }

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

    .nav-link {
        width: 100%;
        padding: 12px 15px;
        font-size: 1.125rem;
    }

    .hero {
        padding: 120px 20px 60px;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: stretch;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }

    .consultation-buttons {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }

    .services-grid,
    .contact-grid {
        grid-template-columns: 1fr;
    }

    section {
        padding: 60px 20px;
    }
}

@media (max-width: 480px) {
    .consultation-buttons {
        grid-template-columns: 1fr;
    }

    .chatbot-container {
        padding: 20px;
    }

    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
    }
}

/* Scroll Animations */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Loading Animation */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.loading {
    animation: pulse 1.5s ease-in-out infinite;
}
