/* ============================================================
   responsive.css - 반응형 디자인 (미디어 쿼리)

   설명: 화면 크기에 따라 레이아웃을 변경합니다.
         PC → 태블릿 → 모바일 순서로 적용됩니다.

   브레이크포인트:
   - 태블릿: 1023px 이하
   - 모바일: 767px 이하
   ============================================================ */

/* ============================================================
   태블릿 (768px ~ 1023px)
   ============================================================ */
@media (max-width: 1023px) {

    /* 히어로 배너 높이 줄임 */
    .hero {
        height: 450px;
    }

    .hero__title {
        font-size: 36px;
    }

    .hero__description {
        font-size: 16px;
    }

    /* 섹션 제목 크기 조절 */
    .section-title {
        font-size: 30px;
    }

    /* 카드 그리드: 3열 → 2열 */
    .card-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* 뉴스 카드 그리드: 4열 → 2열 */
    .card-grid--4 {
        grid-template-columns: repeat(2, 1fr);
    }

    /* 푸터: 4열 → 2열 */
    .footer__grid {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-lg);
    }

    /* CEO 섹션: 2열 유지, 이미지 작게 */
    .ceo-section {
        grid-template-columns: 250px 1fr;
    }

    /* 비전/미션 카드: 패딩 줄임 */
    .vision-card {
        padding: var(--space-lg);
    }

    /* 핵심가치: 4열 → 2열 */
    .values-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* 타임라인: 중앙선 → 왼쪽선 */
    .timeline::before {
        left: 20px;
    }

    .timeline__item,
    .timeline__item:nth-child(even) {
        padding-left: 60px;
        padding-right: 0;
        justify-content: flex-start;
    }

    .timeline__item::after,
    .timeline__item:nth-child(even)::after {
        left: 20px;
    }

    .timeline__content {
        max-width: 100%;
    }

    /* 뉴스 카드: 이미지 작게 */
    .news-article {
        grid-template-columns: 200px 1fr;
    }

    /* 모달: 1열로 */
    .modal__body {
        grid-template-columns: 1fr;
    }

    /* 페이지 배너 */
    .page-banner__title {
        font-size: 36px;
    }
}

/* ============================================================
   모바일 (767px 이하)
   ============================================================ */
@media (max-width: 767px) {

    /* 본문 상단 여백 (헤더 높이) */
    body {
        padding-top: 60px;
    }

    /* 헤더 높이 줄임 */
    .header {
        height: 60px;
    }

    .header__logo-text {
        font-size: 16px;
    }

    /* 네비게이션 메뉴: 숨김 → 모바일 메뉴로 전환 */
    .nav {
        position: fixed;
        top: 60px;
        left: 0;
        width: 100%;
        height: calc(100vh - 60px);
        background-color: var(--color-dark-navy);
        flex-direction: column;
        align-items: flex-start;
        padding: var(--space-lg);
        transform: translateX(-100%);     /* 왼쪽으로 숨김 */
        transition: transform var(--transition-normal);
        overflow-y: auto;
        z-index: 999;
    }

    /* 모바일 메뉴 열린 상태 */
    .nav.active {
        transform: translateX(0);
    }

    .nav__list {
        flex-direction: column;
        width: 100%;
        gap: 0;
    }

    .nav__link {
        padding: 14px 0;
        font-size: 16px;
        border-bottom: 1px solid rgba(255,255,255,0.1);
        width: 100%;
    }

    /* 드롭다운 메뉴: 모바일에서는 아래로 펼침 */
    .nav__dropdown {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        background-color: rgba(255,255,255,0.08);
        border-radius: 0;
        display: none;
    }

    .nav__item.active .nav__dropdown {
        display: block;
    }

    .nav__dropdown-link {
        color: var(--color-text-light);
        padding: 10px 20px;
    }

    /* 모바일 햄버거 버튼 표시 */
    .mobile-menu-btn {
        display: flex;
    }

    /* 언어 선택: 모바일에서도 표시 */
    .header__actions .btn {
        display: none;             /* 문의하기 버튼 숨김 */
    }

    /* 히어로 배너 */
    .hero {
        height: 400px;
    }

    .hero__title {
        font-size: 28px;
    }

    .hero__description {
        font-size: 14px;
    }

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

    .hero__arrow {
        width: 36px;
        height: 36px;
        font-size: 16px;
    }

    /* 섹션 */
    .section {
        padding: var(--space-xl) 0;
    }

    .section-title {
        font-size: 24px;
    }

    /* 카드 그리드: 1열 */
    .card-grid,
    .card-grid--4,
    .card-grid--2 {
        grid-template-columns: 1fr;
    }

    /* 푸터: 1열 */
    .footer__grid {
        grid-template-columns: 1fr;
    }

    .footer__bottom {
        flex-direction: column;
        gap: var(--space-md);
        text-align: center;
    }

    /* CEO 섹션: 1열 (이미지 위, 텍스트 아래) */
    .ceo-section {
        grid-template-columns: 1fr;
    }

    .ceo-section__image {
        width: 200px;
        height: 250px;
        margin: 0 auto;
    }

    /* 비전/미션: 1열 */
    .vision-grid {
        grid-template-columns: 1fr;
    }

    /* 핵심가치: 2열 유지 */
    .values-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* 고객지원: 1열 */
    .support-grid {
        grid-template-columns: 1fr;
    }

    /* 폼 2열 → 1열 */
    .form-row {
        grid-template-columns: 1fr;
    }

    /* 뉴스 카드: 세로 배치 */
    .news-grid {
        grid-template-columns: 1fr;
    }

    .news-article {
        grid-template-columns: 1fr;
    }

    .news-article__image {
        height: 200px;
    }

    /* 모달: 전체 화면 */
    .modal {
        width: 95%;
        max-height: 85vh;
    }

    .modal__body {
        grid-template-columns: 1fr;
    }

    /* 페이지 배너 */
    .page-banner {
        padding: var(--space-xl) 0;
    }

    .page-banner__title {
        font-size: 28px;
    }

    .page-banner__subtitle {
        font-size: 16px;
    }

    /* 제품 특징 아이콘 */
    .product-features {
        gap: var(--space-lg);
    }

    /* 버튼 크기 조절 */
    .btn {
        padding: 10px 20px;
        font-size: 14px;
    }
}

/* ============================================================
   아주 작은 화면 (480px 이하)
   ============================================================ */
@media (max-width: 480px) {
    .hero {
        height: 350px;
    }

    .hero__title {
        font-size: 22px;
    }

    .values-grid {
        grid-template-columns: 1fr;
    }

    .product-features {
        flex-direction: column;
        align-items: center;
    }
}
