/* ==========================================
   모바일 반응형 최적화
   ========================================== */

/* 태블릿 (768px 이하) */
@media (max-width: 768px) {

    /* ── 헤더 ── */
    .header-content {
        position: relative;
        justify-content: center;
        padding: 15px 0;
        gap: 0;
    }

    .logo {
        text-align: center;
    }

    .logo h1 {
        font-size: 14px;
        text-align: center;
    }

    /* 데스크톱 네비/액션 숨김 */
    .desktop-nav {
        display: none !important;
    }

    .desktop-actions {
        display: none !important;
    }

    /* 햄버거 메뉴 표시 - 우측 고정 */
    .mobile-menu-toggle {
        display: flex !important;
        position: absolute;
        right: 0;
        top: 50%;
        transform: translateY(-50%);
        width: 24px;
        height: 20px;
    }

    .mobile-menu-toggle span {
        height: 2px;
    }

    /* 모바일 메뉴 패널 */
    .mobile-menu-panel {
        display: block;
    }

    .mobile-nav {
        display: block !important;
    }

    .mobile-header-actions {
        display: flex !important;
    }

    /* ── 페이지 헤더 ── */
    .page-header {
        padding: 30px 0;
        margin-bottom: 30px;
    }

    .page-header h1 {
        font-size: 24px;
    }

    .page-header .subtitle {
        font-size: 14px;
    }

    /* ── 메인 배너 ── */
    .hero-banner {
        padding: 10px 0;
    }

    .hero-banner-image {
        padding: 0 10px;
    }

    .hero-banner-image img {
        border-radius: 8px;
    }

    /* ── 채용공고 섹션 ── */
    .job-listings {
        padding: 40px 0;
    }

    .section-header {
        flex-direction: row;
        align-items: center;
        margin-bottom: 20px;
    }

    .section-header h2 {
        font-size: 20px;
        flex: 1;
    }

    .section-header .more-link {
        font-size: 13px;
        flex-shrink: 0;
    }

    /* 모바일 페이지네이션 */
    .mobile-pagination {
        display: flex;
        justify-content: center;
        align-items: center;
        gap: 6px;
        margin-top: 16px;
    }

    .mobile-pagination button {
        width: 32px;
        height: 32px;
        border: 1px solid #e2e8f0;
        background: white;
        border-radius: 8px;
        font-size: 13px;
        font-weight: 500;
        color: #666;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.2s ease;
    }

    .mobile-pagination button.active {
        background: #006B7D;
        color: white;
        border-color: #006B7D;
        font-weight: 700;
    }

    .mobile-pagination button:hover:not(.active) {
        background: #f0f0f0;
    }

    .mobile-pagination button.page-arrow {
        font-size: 15px;
        color: #999;
    }

    .company-grid {
        grid-template-columns: 1fr;
        gap: 16px;
        background: transparent;
        border-radius: 0;
        box-shadow: none;
        overflow: visible;
    }

    .company-card {
        flex-direction: row;
        align-items: center;
        padding: 14px 16px;
        border-radius: 12px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.07);
        border-bottom: none;
        gap: 14px;
    }

    .company-card:last-child {
        border-bottom: none;
    }

    .company-card:hover {
        transform: none;
        box-shadow: none;
        background: #f8fafe;
    }

    .company-header {
        margin-bottom: 0;
        flex-shrink: 0;
    }

    .company-logo {
        width: 50px;
        height: 50px;
        border-radius: 10px;
        background: #f5f5f5;
    }

    .company-logo img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        border-radius: 10px;
    }

    .company-info {
        flex: 1;
        margin-bottom: 0;
        min-width: 0;
    }

    .company-info h3 {
        font-size: 14px;
        margin-bottom: 4px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .company-industry {
        font-size: 12px;
        color: #999;
        margin-bottom: 2px;
    }

    .job-count {
        font-size: 12px;
        margin-bottom: 0 !important;
    }

    .job-status {
        display: none;
    }

    .btn-view {
        flex-shrink: 0;
        padding: 7px 12px;
        font-size: 12px;
        border-radius: 6px;
        white-space: nowrap;
    }

    /* ── 공지사항/취업정보 섹션 ── */
    .info-section {
        padding: 25px 0;
        overflow: hidden;
    }

    .info-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .info-card {
        padding: 0;
        box-shadow: none;
        background: transparent;
        border-radius: 0;
        overflow: hidden;
    }

    .info-card h3 {
        font-size: 16px;
        font-weight: 700;
        margin-bottom: 8px;
        padding: 0 4px;
        border-bottom: none;
        color: #2c3e50;
    }

    .notice-list {
        background: white;
        border-radius: 12px;
        box-shadow: 0 2px 10px rgba(0,0,0,0.08);
        overflow: hidden;
        width: 100%;
    }

    .notice-list li {
        margin-bottom: 0;
        border-bottom: 1px solid #f2f2f2;
    }

    .notice-list li:last-child {
        border-bottom: none;
    }

    .notice-list a {
        padding: 13px 14px;
        border-radius: 0;
        display: flex;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        gap: 8px;
    }

    .notice-list a:hover {
        background: #fafbfc;
    }

    .notice-title {
        font-size: 13px;
        line-height: 1.4;
        color: #333;
        flex: 1;
        min-width: 0;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        display: block;
    }

    .notice-date {
        font-size: 11px;
        color: #b0b0b0;
        margin-left: 0;
        flex-shrink: 0;
    }

    .view-all {
        display: block;
        margin-top: 8px;
        padding: 10px;
        font-size: 13px;
        border-radius: 10px;
        width: 100%;
        box-sizing: border-box;
    }

    /* ── 참여방법 배너 ── */
    .participation-banner {
        padding: 40px 0;
    }

    .banner-content h2 {
        font-size: 22px;
        margin-bottom: 20px;
    }

    .steps {
        flex-direction: column;
        gap: 15px;
    }

    .step {
        max-width: 100%;
        width: 100%;
    }

    .step-number {
        width: 60px;
        height: 60px;
        font-size: 12px;
    }

    .step-arrow {
        display: none;
    }

    /* ── 스폰서 ── */
    .sponsors {
        padding: 40px 0;
    }

    .sponsors h3 {
        font-size: 18px;
        margin-bottom: 25px;
    }

    .sponsor-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 12px;
    }

    .sponsor-item {
        padding: 12px;
        height: 60px;
    }

    /* ── 푸터 ── */
    .main-footer {
        padding: 30px 0 20px;
    }

    .footer-info h3 {
        font-size: 16px;
    }

    .organizer {
        font-size: 14px;
    }

    address {
        font-size: 11px;
        line-height: 1.8;
    }

    .footer-links {
        flex-wrap: wrap;
        gap: 12px;
        justify-content: center;
    }

    .footer-links a {
        font-size: 12px;
    }

    /* ── 로그인 페이지 ── */
    .login-section {
        padding: 30px 0 !important;
    }

    .login-container {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }

    .login-card {
        padding: 30px 20px !important;
        border-radius: 12px !important;
    }

    .login-header h1 {
        font-size: 24px !important;
    }

    .login-header p {
        font-size: 14px !important;
    }

    .form-group {
        margin-bottom: 18px !important;
    }

    .form-control {
        padding: 12px 14px !important;
        font-size: 14px !important;
    }

    .btn-login {
        padding: 14px !important;
        font-size: 15px !important;
    }

    .social-login {
        grid-template-columns: 1fr !important;
        gap: 10px !important;
    }

    .btn-social {
        padding: 12px !important;
        font-size: 14px !important;
    }

    .login-benefits {
        padding: 25px 20px !important;
    }

    .login-benefits h2 {
        font-size: 20px !important;
    }

    .benefits-list li {
        gap: 15px;
        margin-bottom: 20px;
        padding-bottom: 20px;
    }

    .benefit-icon {
        width: 40px;
        height: 40px;
        font-size: 18px;
        border-radius: 10px;
    }

    .benefit-content h3 {
        font-size: 15px;
    }

    .benefit-content p {
        font-size: 13px;
    }

    /* ── 회원가입 페이지 ── */
    .signup-section {
        padding: 30px 0 !important;
    }

    .signup-container {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }

    .signup-card {
        padding: 30px 20px !important;
    }

    .signup-header h1 {
        font-size: 24px !important;
    }

    .signup-header p {
        font-size: 14px !important;
    }

    .signup-form .form-row {
        grid-template-columns: 1fr !important;
        gap: 15px !important;
    }

    /* ── 관리자 로그인 ── */
    .admin-login-section {
        padding: 30px 0 !important;
    }

    .admin-login-section .login-card {
        padding: 30px 20px !important;
        max-width: 100% !important;
    }

    .admin-login-section .login-header h1 {
        font-size: 24px !important;
    }

    /* ── About 페이지 ── */
    .about-section {
        padding: 30px 0;
    }

    .tab-menu {
        gap: 0;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        flex-wrap: nowrap;
    }

    .tab-button {
        padding: 12px 15px;
        font-size: 14px;
        white-space: nowrap;
        flex-shrink: 0;
    }

    .event-banner-large {
        padding: 30px 20px;
        border-radius: 12px;
        margin-bottom: 30px;
    }

    .banner-text h2 {
        font-size: 24px;
        margin-bottom: 20px;
    }

    .event-details-large p {
        font-size: 14px;
        flex-direction: column;
        gap: 5px;
    }

    .event-details-large strong {
        min-width: auto;
    }

    .organizer-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 15px;
    }

    .organizer-logo {
        width: 60px;
        height: 60px;
        font-size: 10px;
    }

    .organizer-item p {
        font-size: 12px;
    }

    .participation-guide h2 {
        font-size: 22px;
        margin-bottom: 25px;
    }

    /* ── 팝업 ── */
    .popup-content {
        width: 95%;
        max-height: 85vh;
    }

    .popup-header {
        padding: 20px;
    }

    .popup-header h3 {
        font-size: 18px;
    }

    .popup-body {
        padding: 25px 20px;
    }

    .event-title {
        font-size: 28px;
    }

    .event-subtitle {
        font-size: 15px;
    }

    .popup-footer {
        padding: 15px 20px;
    }

    /* ── 컨테이너 ── */
    .container {
        padding: 0 15px;
    }
}

/* 소형 모바일 (480px 이하) */
@media (max-width: 480px) {

    .logo h1 {
        font-size: 13px;
    }

    .company-logo {
        width: 44px;
        height: 44px;
    }

    .company-info h3 {
        font-size: 13px;
    }

    .sponsor-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .organizer-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .login-card {
        padding: 25px 15px !important;
    }

    .signup-card {
        padding: 25px 15px !important;
    }

    .form-options {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }

    .footer-links {
        flex-direction: column;
        align-items: center;
        gap: 8px;
    }

    address {
        font-size: 10px;
    }
}

/* 터치 디바이스 최적화 */
@media (hover: none) and (pointer: coarse) {
    .btn-login,
    .btn-social,
    .btn-view,
    .btn-primary,
    .btn-secondary,
    .btn-back,
    .btn-signup,
    .header-link,
    .user-type-btn {
        min-height: 44px;
    }

    .mobile-nav a {
        min-height: 48px;
        display: flex;
        align-items: center;
    }

    .form-control {
        font-size: 16px !important; /* iOS zoom 방지 */
    }
}
