/* static/css/index.css */

.main-header {
    text-align: center;
    padding: 60px 20px 0;
    max-width: 800px;
    margin: 0 auto;
}

.main-title {
    font-size: 3.5rem;
    color: var(--color-text-main);
    font-weight: 800;
    margin-bottom: 16px;
    line-height: 1.2;
    letter-spacing: -0.5px;
}

.main-slogan {
    font-size: 1.25rem;
    color: var(--color-text-minor);
    line-height: 1.6;
}

.home-search-form {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    max-width: 560px;
    margin: 32px auto 0;
}

.home-search-form .input-wrapper {
    position: relative;
    flex: 1;
    display: flex;
    align-items: center;
}

.home-search-form .search-icon {
    position: absolute;
    left: 16px;
    color: var(--color-text-minor);
    pointer-events: none;
}

.home-search-input {
    width: 100%;
    padding: 12px 16px 12px 42px;
    font-size: 1rem;
    color: var(--color-text-main);
    background-color: var(--color-bg);
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 8px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.home-search-input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.06);
}

body[data-theme="dark"] .home-search-input {
    border-color: rgba(255, 255, 255, 0.15);
}

.home-search-btn {
    padding: 12px 24px;
    font-size: 1rem;
    white-space: nowrap;
}

.home-hero, .home-news,
.home-flowchart, .home-script, .home-competency {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 40px;
    padding: 60px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.hero-content, .news-content,
.flowchart-content, .script-content, .competency-content {
    flex: 1;
    max-width: 500px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
}

.hero-image, .news-image,
.flowchart-image, .script-image, .competency-image {
    flex: 1;
    display: flex;
    justify-content: center;
}

.hero-image img, .news-image img,
.flowchart-image img, .script-image img, .competency-image img {
    max-width: 100%;
    height: auto;
    object-fit: contain;
    border-radius: 12px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.08), 0 4px 12px rgba(0, 0, 0, 0.04);
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

body[data-theme="dark"] .hero-image img,
body[data-theme="dark"] .news-image img,
body[data-theme="dark"] .flowchart-image img,
body[data-theme="dark"] .script-image img,
body[data-theme="dark"] .competency-image img {
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.3), 0 4px 12px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.hero-image img:hover, .news-image img:hover,
.flowchart-image img:hover, .script-image img:hover, .competency-image img:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12), 0 8px 16px rgba(0, 0, 0, 0.08);
}

body[data-theme="dark"] .hero-image img:hover,
body[data-theme="dark"] .news-image img:hover,
body[data-theme="dark"] .flowchart-image img:hover,
body[data-theme="dark"] .script-image img:hover,
body[data-theme="dark"] .competency-image img:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), 0 8px 16px rgba(0, 0, 0, 0.3);
}

.home-hero h1, .home-news h2,
.home-flowchart h2, .home-script h2, .home-competency h2 {
    font-size: 2.5rem;
    color: var(--color-text-main);
    margin-bottom: 20px;
    font-weight: 700;
}

.hero-slogan {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--color-primary);
    margin-bottom: 20px;
}

.hero-desc, .news-desc,
.flowchart-desc, .script-desc, .competency-desc {
    font-size: 1.125rem;
    color: var(--color-text-minor);
    line-height: 1.6;
    margin-bottom: 30px;
}

.action-btn {
    padding: 12px 28px;
    font-size: 1.125rem;
    font-weight: 600;
    color: #fff;
    background-color: var(--color-primary);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.action-btn:hover {
    background-color: var(--color-primary-light);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

/* Responsive Breakpoint: 768px */
@media (max-width: 768px) {
    .main-header {
        padding: 40px 20px 0;
        text-align: left;
    }

    .main-title {
        font-size: 2.5rem;
    }

    .main-slogan {
        font-size: 1.125rem;
    }

    .home-hero, .home-news,
    .home-flowchart, .home-script, .home-competency {
        flex-direction: column;
        padding: 40px 20px;
        text-align: left;
        gap: 30px;
    }

    .hero-content, .news-content,
    .flowchart-content, .script-content, .competency-content {
        align-items: flex-start;
    }

    /* For news, let's show image first by reversing the naturally wrapped flow if needed,
       but default HTML order puts news-image then news-content, which is naturally image first. */

    .home-hero h1, .home-news h2,
    .home-flowchart h2, .home-script h2, .home-competency h2 {
        font-size: 2rem;
    }

    .hero-slogan {
        font-size: 1.25rem;
    }

    .hero-desc, .news-desc,
    .flowchart-desc, .script-desc, .competency-desc {
        font-size: 1rem;
        margin-bottom: 24px;
    }

    .home-search-form {
        flex-direction: column;
        align-items: stretch;
        margin-top: 24px;
    }

    .home-search-btn {
        width: 100%;
    }
}
