/* ===================================
   Sidaein Academy - Custom Styles
   전문 교육기관 스타일
   =================================== */

/* CSS Custom Properties */
:root {
    --primary: #1E3A5F;
    --primary-light: #2C5282;
    --accent: #E74C3C;
    --accent-light: #FC8181;
    --background: #FFFFFF;
    --text-dark: #1F2937;
    --text-gray: #6B7280;
    --border-light: #E5E7EB;
}

/* Base Styles */
* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--background);
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.3;
}

/* Links */
a {
    text-decoration: none;
    transition: color 0.3s ease;
}

/* Buttons */
.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background-color: var(--accent);
    color: white;
    padding: 1rem 2rem;
    border-radius: 0.5rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background-color: #C0392B;
    transform: translateY(-2px);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background-color: var(--primary);
    color: white;
    padding: 1rem 2rem;
    border-radius: 0.5rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

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

/* Header Styles */
header {
    transition: all 0.3s ease;
}

header.scrolled {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

/* Navigation */
nav a {
    position: relative;
}

nav a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--accent);
    transition: width 0.3s ease;
}

nav a:hover::after,
nav a.active::after {
    width: 100%;
}

/* Course Tabs */
.course-tab {
    background-color: #F3F4F6;
    color: var(--text-gray);
    border: 2px solid transparent;
}

.course-tab:hover {
    background-color: #E5E7EB;
}

.course-tab.active {
    background-color: var(--primary);
    color: white;
}

/* Course Content */
.course-content {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease;
}

.course-content.active {
    opacity: 1;
    transform: translateY(0);
}

.course-content.hidden {
    display: none;
}

/* FAQ Accordion */
.faq-toggle {
    background: none;
    border: none;
    cursor: pointer;
}

.faq-toggle i {
    transition: transform 0.3s ease;
}

.faq-toggle.active i {
    transform: rotate(45deg);
}

.faq-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.faq-content.active {
    max-height: 500px;
}

/* Counter Animation */
.counter {
    display: inline-block;
}

/* Cards Hover Effects */
.group:hover .group-hover\:scale-110 {
    transform: scale(1.1);
}

/* Form Styles */
input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(30, 58, 95, 0.1);
}

input[type="checkbox"] {
    accent-color: var(--primary);
}

/* Custom Checkbox */
input[type="checkbox"]:checked {
    background-color: var(--primary);
    border-color: var(--primary);
}

/* Form Checkbox Labels */
label:has(input[type="checkbox"]:checked) {
    border-color: var(--primary) !important;
    background-color: rgba(30, 58, 95, 0.05) !important;
}

/* Timeline */
.timeline-item {
    position: relative;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background-color: rgba(30, 58, 95, 0.2);
    transform: translateX(-50%);
}

/* Pricing Cards */
.pricing-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.pricing-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

/* Teacher Cards */
.teacher-card {
    transition: transform 0.3s ease;
}

.teacher-card:hover {
    transform: translateY(-8px);
}

/* Testimonial Cards */
.testimonial-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.testimonial-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Gallery Grid */
.gallery-item {
    transition: transform 0.3s ease;
}

.gallery-item:hover {
    transform: scale(1.02);
}

/* Stats Section */
.stat-circle {
    position: relative;
}

.stat-circle::before {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent), transparent);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 0.5;
    }
    50% {
        opacity: 1;
    }
}

/* Scroll Animations */
[data-aos] {
    pointer-events: none;
}

[data-aos].aos-animate {
    pointer-events: auto;
}

/* Hero Background */
.hero-bg {
    position: relative;
    overflow: hidden;
}

.hero-bg::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(30, 58, 95, 0.95), rgba(30, 58, 95, 0.8));
}

/* Gradient Overlays */
.gradient-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
}

.gradient-accent {
    background: linear-gradient(135deg, var(--accent) 0%, #C0392B 100%);
}

/* Loading States */
.loading {
    position: relative;
    overflow: hidden;
}

.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0% {
        left: -100%;
    }
    100% {
        left: 100%;
    }
}

/* Mobile Menu Animation */
#mobile-menu {
    transition: all 0.3s ease;
    max-height: 0;
    overflow: hidden;
}

#mobile-menu.active {
    max-height: 400px;
}

/* Scroll to Top Button */
.scroll-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 50px;
    height: 50px;
    background-color: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 40;
    box-shadow: 0 4px 15px rgba(30, 58, 95, 0.3);
}

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

.scroll-to-top:hover {
    background-color: var(--accent);
    transform: translateY(-4px);
}

/* Modal Styles */
.modal-overlay {
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.modal-overlay.active .modal-content {
    transform: scale(1);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-light);
}

/* Selection */
::selection {
    background-color: var(--primary);
    color: white;
}

/* Focus States */
*:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* Print Styles */
@media print {
    header, footer, .no-print {
        display: none !important;
    }

    body {
        color: black;
        background: white;
    }

    a[href]::after {
        content: " (" attr(href) ")";
    }
}

/* Responsive Utilities */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .timeline-item::before {
        display: none;
    }

    .pricing-card.featured {
        transform: none;
    }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    :root {
        --primary: #000080;
        --accent: #CC0000;
    }

    .btn-primary,
    .btn-secondary {
        border: 2px solid currentColor;
    }
}

/* Dark Mode Support (optional) */
@media (prefers-color-scheme: dark) {
    /* Uncomment to enable dark mode */
    /*
    :root {
        --background: #1F2937;
        --text-dark: #F9FAFB;
        --text-gray: #9CA3AF;
    }
    */
}
