/* Home page specific styles */
.hero-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 4rem 2rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    margin-bottom: 3rem;
    position: relative;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 15px;
    pointer-events: none;
}

.hero-section * {
    position: relative;
    z-index: 1;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 2rem;
}

.stat-item {
    text-align: center;
    padding: 1rem;
    background: rgba(255,255,255,0.2);
    border-radius: 10px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.3);
}

.stat-number {
    font-size: 2rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
    color: #ffffff;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

.stat-label {
    font-size: 0.9rem;
    color: #ffffff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
    opacity: 1;
}

/* Featured Tools Cards */
.tool-card-main {
    background: white;
    border-radius: 10px;
    padding: 1.25rem;
    text-align: center;
    transition: all 0.3s ease;
    border: none;
    box-shadow: 0 3px 12px rgba(0,0,0,0.08);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.tool-card-main:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.tool-icon {
    font-size: 2.5rem;
    color: #667eea;
    margin-bottom: 1rem;
}

.tool-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: #333;
}

.tool-description {
    color: #666;
    margin-bottom: 1rem;
    flex-grow: 1;
    font-size: 0.85rem;
    line-height: 1.4;
}

/* Category Sections */
.category-section {
    margin-bottom: 3rem;
    padding: 2rem 0;
}

.category-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: #333;
    position: relative;
    padding-bottom: 0.5rem;
}

.category-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 3px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 2px;
}

/* Tool Items */
.tool-item {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 10px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: all 0.3s ease;
    height: 100%;
}

.tool-item:hover {
    border-color: #667eea;
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.1);
    transform: translateY(-2px);
}

.tool-icon-small {
    font-size: 1.5rem;
    color: #667eea;
    min-width: 40px;
}

.tool-info {
    flex-grow: 1;
}

.tool-name {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
    color: #333;
}

.tool-desc {
    font-size: 0.85rem;
    color: #666;
    margin: 0;
    line-height: 1.4;
}

/* CTA Section */
.cta-section {
    margin-top: 4rem;
}

.cta-section .card {
    border: none;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 15px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-section {
        padding: 2rem 1rem;
    }

    .display-4 {
        font-size: 2rem;
    }

    .hero-stats {
        flex-direction: column;
        gap: 1rem;
    }

    .tool-card-main {
        padding: 1rem;
    }

    .tool-icon {
        font-size: 2rem;
        margin-bottom: 0.75rem;
    }

    .tool-title {
        font-size: 1rem;
    }

    .tool-description {
        font-size: 0.8rem;
    }

    .tool-item {
        flex-direction: column;
        text-align: center;
        gap: 0.5rem;
    }

    .tool-info {
        margin-bottom: 1rem;
    }
}

@media (max-width: 576px) {
    .hero-section {
        padding: 1.5rem 1rem;
    }

    .category-section {
        padding: 1rem 0;
    }

    .tool-item {
        padding: 1rem;
    }
}

/* Animation */
.tool-card-main,
.tool-item {
    animation: fadeInUp 0.6s ease forwards;
}

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

/* Stagger animation delays */
.tool-card-main:nth-child(1) { animation-delay: 0.1s; }
.tool-card-main:nth-child(2) { animation-delay: 0.2s; }
.tool-card-main:nth-child(3) { animation-delay: 0.3s; }
.tool-card-main:nth-child(4) { animation-delay: 0.4s; }

.tool-item:nth-child(1) { animation-delay: 0.1s; }
.tool-item:nth-child(2) { animation-delay: 0.2s; }
.tool-item:nth-child(3) { animation-delay: 0.3s; }

/* Footer */
.footer {
    background: #2c3e50;
    color: white;
    padding: 2rem 0;
    margin-top: 4rem;
}

.footer h5 {
    margin-bottom: 1rem;
}

.footer a {
    color: #ecf0f1;
    text-decoration: none;
}

.footer a:hover {
    color: #3498db;
}

/* 도구 모달 스타일 */
#toolModal .modal-dialog {
    max-width: 90%;
    margin: 1.75rem auto;
}

#toolModal .modal-content {
    border: none;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

#toolModal .modal-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-bottom: none;
    border-radius: 15px 15px 0 0;
}

#toolModal .modal-header .btn-close {
    filter: invert(1);
}

#toolModal .modal-body {
    padding: 0;
    max-height: 80vh;
    overflow-y: auto;
}

/* 모달 내 도구 컨텐츠 스타일 */
#toolContent {
    min-height: 400px;
    padding: 1.5rem;
    width: 100%;
    height: 100%;
}

/* 도구별 컨테이너 스타일 */
#toolContent .container-fluid {
    padding: 0 !important;
}

#toolContent .container {
    max-width: 100% !important;
    padding: 0 !important;
}

/* 모달 내 버튼 스타일 개선 */
#toolModal .btn {
    margin: 0.25rem;
}

/* 모달 애니메이션 개선 */
.modal.fade .modal-dialog {
    transition: transform 0.3s ease-out;
    transform: translate(0, -50px);
}

.modal.show .modal-dialog {
    transform: translate(0, 0);
}

/* 방문자 통계 스타일 */
.visitor-stats-section {
    margin-top: 2rem;
}

.stats-container {
    border: 1px solid rgba(255,255,255,0.2);
}

.stat-item h5, .stat-item h6 {
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.daily-stats .day-stat {
    text-align: center;
    min-width: 60px;
}

.daily-stats .badge {
    font-size: 0.9rem;
    padding: 0.375rem 0.5rem;
}

.daily-stats small {
    font-size: 0.75rem;
    line-height: 1;
}

@media (max-width: 768px) {
    .stats-container {
        margin: 0 1rem;
    }

    .daily-stats {
        flex-direction: column;
        align-items: center;
    }

    .day-stat {
        margin: 0.25rem 0 !important;
    }
}