/**
 * 파일명: acts-phase2.css
 * 파일위치: /joyn-members-pro/modules/acts/assets/
 * 
 * Acts 모듈 Phase 2 스타일
 * 리더보드, 월간 베스트, 팀, 반응형
 * 
 * @since 1.1.0
 */

/* =========================================================
   월간 베스트 배너
   ======================================================= */
.acts-monthly-banner {
    background: linear-gradient(135deg, #1B3A5C 0%, #2A5A8C 100%);
    border-radius: 16px;
    padding: 28px;
    margin-bottom: 24px;
    color: #fff;
}
.acts-monthly-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.acts-monthly-title i { font-size: 22px; color: #D4A843; }
.acts-monthly-winners {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}
.acts-winner-card {
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 20px 24px;
    text-align: center;
    min-width: 140px;
    transition: transform 0.2s;
}
.acts-winner-card:hover { transform: translateY(-4px); }
.acts-winner-1 { border: 2px solid #FFD700; }
.acts-winner-2 { border: 2px solid #C0C0C0; }
.acts-winner-3 { border: 2px solid #CD7F32; }
.acts-winner-medal { font-size: 28px; margin-bottom: 8px; }
.acts-winner-avatar {
    width: 64px; height: 64px;
    border-radius: 14px;
    border: 3px solid rgba(255,255,255,0.3);
    margin-bottom: 8px;
    object-fit: cover;
}
.acts-winner-name { font-weight: 700; font-size: 15px; margin-bottom: 4px; }
.acts-winner-score { font-size: 18px; font-weight: 700; color: #D4A843; margin-top: 6px; }
.acts-winner-bonus { font-size: 12px; color: rgba(255,255,255,0.7); margin-top: 2px; }

/* =========================================================
   내 순위 바
   ======================================================= */
.acts-my-rank-bar {
    background: linear-gradient(90deg, #FFF8E1, #FFF3E0);
    border: 1px solid #FFE0B2;
    border-radius: 10px;
    padding: 12px 20px;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
}
.acts-my-rank-bar i { color: #FF9800; font-size: 18px; }
.acts-my-rank-bar strong { color: #E65100; font-size: 20px; }
.acts-my-rank-period { color: #999; font-size: 13px; }

/* =========================================================
   리더보드 필터
   ======================================================= */
.acts-lb-filters {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    gap: 12px;
    flex-wrap: wrap;
}
.acts-lb-tabs { display: flex; gap: 4px; }
.acts-lb-tab {
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    color: #666;
    text-decoration: none;
    transition: all 0.2s;
    background: #f5f5f5;
}
.acts-lb-tab:hover { background: #e0e0e0; color: #333; }
.acts-lb-tab.active { background: #1B3A5C; color: #fff; }
.acts-lb-sort-group { display: flex; gap: 8px; }
.acts-lb-sort,
.acts-lb-level-filter {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 13px;
    background: #fff;
}

/* =========================================================
   리더보드 리스트
   ======================================================= */
.acts-lb-list { display: flex; flex-direction: column; gap: 4px; }
.acts-lb-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 18px;
    background: #fff;
    border-radius: 12px;
    border: 1px solid #f0f0f0;
    transition: all 0.2s;
}
.acts-lb-row:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.06); transform: translateY(-1px); }
.acts-lb-me { background: #FFF8E1; border-color: #FFE0B2; }
.acts-rank-gold { border-left: 4px solid #FFD700; }
.acts-rank-silver { border-left: 4px solid #C0C0C0; }
.acts-rank-bronze { border-left: 4px solid #CD7F32; }

.acts-lb-rank { width: 40px; text-align: center; flex-shrink: 0; }
.acts-lb-medal { font-size: 24px; }
.acts-lb-number { font-size: 16px; font-weight: 700; color: #999; }
.acts-lb-avatar { flex-shrink: 0; }
.acts-lb-avatar img { width: 44px; height: 44px; border-radius: 10px; object-fit: cover; }
.acts-lb-info { flex: 1; min-width: 0; }
.acts-lb-name { font-weight: 700; font-size: 15px; color: #222; display: flex; align-items: center; gap: 6px; }
.acts-lb-me-badge {
    background: #FF9800; color: #fff;
    font-size: 10px; font-weight: 700;
    padding: 1px 6px; border-radius: 4px;
}
.acts-lb-meta { display: flex; align-items: center; gap: 8px; margin-top: 2px; }
.acts-lb-specialty { font-size: 12px; color: #999; }
.acts-lb-score { text-align: right; flex-shrink: 0; min-width: 80px; }
.acts-lb-score-main { font-size: 18px; font-weight: 700; color: #1B3A5C; }
.acts-lb-score-unit { font-size: 11px; color: #999; }

/* 공통 배지 */
.acts-badge-sm {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    line-height: 1.4;
}
.acts-badge-lv1 { background: #E8F5E9; color: #2E7D32; }
.acts-badge-lv2 { background: #E3F2FD; color: #1565C0; }
.acts-badge-lv3 { background: #FFF3E0; color: #E65100; }
.acts-badge-lv4 { background: #F3E5F5; color: #7B1FA2; }
.acts-badge-lv5 { background: #FFF8E1; color: #F57F17; }

/* 페이지네이션 */
.acts-lb-pagination { display: flex; justify-content: center; gap: 4px; margin-top: 20px; }
.acts-lb-page-btn {
    width: 36px; height: 36px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 8px;
    font-size: 14px; font-weight: 600;
    color: #666;
    background: #f5f5f5;
    text-decoration: none;
    transition: all 0.2s;
}
.acts-lb-page-btn:hover { background: #e0e0e0; }
.acts-lb-page-btn.active { background: #1B3A5C; color: #fff; }

.acts-lb-empty {
    text-align: center; padding: 60px 20px;
    color: #999;
}
.acts-lb-empty i { font-size: 48px; display: block; margin-bottom: 12px; }

/* =========================================================
   팀 - 공통
   ======================================================= */
.acts-btn {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 10px 18px; border-radius: 10px;
    font-size: 14px; font-weight: 600;
    text-decoration: none; cursor: pointer;
    border: none; transition: all 0.2s;
}
.acts-btn-primary { background: #1B3A5C; color: #fff; }
.acts-btn-primary:hover { background: #2A5A8C; color: #fff; }
.acts-btn-outline { background: transparent; border: 1.5px solid #1B3A5C; color: #1B3A5C; }
.acts-btn-outline:hover { background: #1B3A5C; color: #fff; }
.acts-btn-ghost { background: transparent; color: #666; }
.acts-btn-ghost:hover { background: #f5f5f5; color: #333; }
.acts-btn-sm { padding: 6px 14px; font-size: 13px; }

.acts-team-cat-badge {
    display: inline-block;
    padding: 2px 10px; border-radius: 6px;
    font-size: 12px; font-weight: 600;
    background: #E3F2FD; color: #1565C0;
}

/* =========================================================
   내 팀 배너
   ======================================================= */
.acts-my-team-banner {
    display: flex; align-items: center; gap: 16px;
    background: #fff; border-radius: 12px;
    padding: 16px 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.acts-my-team-icon { font-size: 36px; }
.acts-my-team-info { flex: 1; }
.acts-my-team-name { font-size: 17px; font-weight: 700; }
.acts-my-team-meta { display: flex; gap: 10px; margin-top: 4px; font-size: 13px; color: #666; }

/* =========================================================
   팀 툴바
   ======================================================= */
.acts-team-toolbar {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 20px; flex-wrap: wrap; gap: 10px;
}
.acts-team-cat-tabs { display: flex; gap: 4px; flex-wrap: wrap; }
.acts-team-cat-tab {
    padding: 6px 14px; border-radius: 8px;
    font-size: 13px; font-weight: 600;
    color: #666; background: #f5f5f5;
    text-decoration: none; transition: all 0.2s;
}
.acts-team-cat-tab:hover { background: #e0e0e0; color: #333; }
.acts-team-cat-tab.active { background: #1B3A5C; color: #fff; }

/* =========================================================
   팀 그리드 (목록)
   ======================================================= */
.acts-team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 16px;
}
.acts-team-card {
    display: flex; flex-direction: column; align-items: center;
    background: #fff; border-radius: 14px;
    padding: 24px 20px; text-align: center;
    text-decoration: none; color: inherit;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    transition: all 0.25s;
    position: relative;
}
.acts-team-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
    color: inherit;
}
.acts-team-card-rank {
    position: absolute; top: 10px; left: 14px;
    font-size: 14px; font-weight: 700; color: #999;
}
.acts-team-gold .acts-team-card-rank,
.acts-team-silver .acts-team-card-rank,
.acts-team-bronze .acts-team-card-rank { font-size: 20px; }
.acts-team-card-icon { font-size: 40px; margin-bottom: 8px; }
.acts-team-card-name { font-size: 17px; font-weight: 700; margin-bottom: 6px; }
.acts-team-card-stats {
    display: flex; gap: 14px; margin-top: 10px;
    font-size: 13px; color: #666;
}
.acts-team-card-stats i { margin-right: 2px; }
.acts-team-card-leader {
    display: flex; align-items: center; gap: 6px;
    margin-top: 10px; font-size: 12px; color: #999;
}
.acts-team-card-leader img { border-radius: 50%; }

.acts-team-empty {
    text-align: center; padding: 60px 20px; color: #999;
}
.acts-team-empty i { font-size: 48px; display: block; margin-bottom: 12px; }

/* =========================================================
   팀 상세
   ======================================================= */
.acts-team-header {
    display: flex; gap: 16px; align-items: flex-start;
    background: #fff; border-radius: 14px;
    padding: 24px; margin-bottom: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.acts-team-icon-large { font-size: 48px; flex-shrink: 0; }
.acts-team-header-info { flex: 1; }
.acts-team-header-info h2 { margin: 0 0 6px; font-size: 22px; }
.acts-team-meta-row { display: flex; gap: 12px; font-size: 13px; color: #666; align-items: center; }
.acts-team-desc { margin-top: 8px; font-size: 14px; color: #555; line-height: 1.6; }
.acts-team-header-actions { display: flex; gap: 8px; flex-shrink: 0; flex-wrap: wrap; }

.acts-team-stats-row {
    display: flex; gap: 12px; margin-bottom: 20px; flex-wrap: wrap;
}
.acts-team-stat-item {
    flex: 1; min-width: 120px;
    background: #fff; border-radius: 12px;
    padding: 16px; text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.acts-team-stat-num { font-size: 22px; font-weight: 700; color: #1B3A5C; }
.acts-team-stat-label { font-size: 12px; color: #999; margin-top: 2px; }

.acts-team-detail-grid {
    display: grid; grid-template-columns: 1fr 1fr; gap: 16px;
}
.acts-team-detail-section {
    background: #fff; border-radius: 14px;
    padding: 20px; box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.acts-team-detail-section h3 {
    margin: 0 0 14px; font-size: 16px;
    display: flex; align-items: center; gap: 6px;
}

.acts-team-member-row {
    display: flex; align-items: center; gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid #f5f5f5;
}
.acts-team-member-row:last-child { border-bottom: none; }
.acts-member-avatar { width: 36px; height: 36px; border-radius: 10px; object-fit: cover; }
.acts-member-info { flex: 1; }
.acts-member-name { font-weight: 600; font-size: 14px; }
.acts-member-role { font-size: 11px; margin-left: 6px; padding: 1px 6px; border-radius: 4px; }
.acts-role-leader { background: #FFF3E0; color: #E65100; }
.acts-role-co_leader { background: #E3F2FD; color: #1565C0; }
.acts-role-member { background: #f5f5f5; color: #666; }
.acts-member-pts { font-size: 13px; color: #1B3A5C; font-weight: 600; }

.acts-team-log-item {
    display: flex; gap: 10px; padding: 8px 0;
    border-bottom: 1px solid #f8f8f8;
}
.acts-team-log-item:last-child { border-bottom: none; }
.acts-log-icon {
    width: 28px; height: 28px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 14px; flex-shrink: 0;
    background: #f0f0f0;
}
.acts-log-join { background: #E8F5E9; color: #2E7D32; }
.acts-log-leave { background: #FFEBEE; color: #C62828; }
.acts-log-create { background: #E3F2FD; color: #1565C0; }
.acts-log-content { flex: 1; font-size: 13px; }
.acts-log-content span { display: block; }
.acts-log-content time { color: #999; font-size: 11px; }
.acts-team-log-empty { text-align: center; color: #999; padding: 20px; }

/* =========================================================
   팀 생성 폼
   ======================================================= */
.acts-team-create {
    max-width: 600px; margin: 0 auto;
    background: #fff; border-radius: 14px;
    padding: 32px; box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}
.acts-team-create h2 { margin: 0 0 8px; display: flex; align-items: center; gap: 8px; }
.acts-team-create-note { color: #999; font-size: 13px; margin-bottom: 24px; }
.acts-form-group { margin-bottom: 16px; }
.acts-form-group label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 6px; }
.acts-form-group label .required { color: #e53935; }
.acts-form-group input[type="text"],
.acts-form-group input[type="number"],
.acts-form-group select,
.acts-form-group textarea {
    width: 100%; padding: 10px 14px;
    border: 1.5px solid #ddd; border-radius: 10px;
    font-size: 14px; transition: border-color 0.2s;
}
.acts-form-group input:focus,
.acts-form-group select:focus,
.acts-form-group textarea:focus { border-color: #1B3A5C; outline: none; }
.acts-form-row { display: flex; gap: 12px; }
.acts-form-half { flex: 1; }
.acts-icon-input { text-align: center; font-size: 24px !important; }
.acts-color-input { height: 44px !important; padding: 4px !important; cursor: pointer; }
.acts-form-actions { display: flex; gap: 10px; margin-top: 24px; }

/* =========================================================
   관리자 CSS
   ======================================================= */
.acts-admin-wrap { max-width: 1200px; }
.acts-admin-title { display: flex; align-items: center; gap: 8px; }
.acts-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 14px; margin: 20px 0;
}
.acts-stat-card {
    background: #fff; border-radius: 12px;
    padding: 18px; display: flex; gap: 12px; align-items: center;
    box-shadow: 0 1px 4px rgba(0,0,0,0.06);
    border-left: 4px solid #ddd;
}
.acts-stat-primary { border-left-color: #1B3A5C; }
.acts-stat-warning { border-left-color: #FF9800; }
.acts-stat-success { border-left-color: #4CAF50; }
.acts-stat-info { border-left-color: #2196F3; }
.acts-stat-icon .dashicons { font-size: 28px; width: 28px; height: 28px; color: inherit; }
.acts-stat-number { font-size: 24px; font-weight: 700; }
.acts-stat-label { font-size: 12px; color: #999; }

.acts-admin-row { display: flex; gap: 16px; margin-bottom: 16px; flex-wrap: wrap; }
.acts-admin-card {
    background: #fff; border-radius: 12px;
    padding: 20px; box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}
.acts-admin-card h3 { margin: 0 0 14px; display: flex; justify-content: space-between; align-items: center; }
.acts-admin-half { flex: 1; min-width: 300px; }
.acts-admin-full { flex: 1; min-width: 100%; }
.acts-link { font-size: 13px; font-weight: 400; text-decoration: none; }

.acts-admin-filters { margin-bottom: 16px; }
.acts-admin-filters form { display: flex; gap: 8px; align-items: center; }
.acts-badge-count {
    background: #FF9800; color: #fff;
    font-size: 13px; font-weight: 700;
    padding: 2px 10px; border-radius: 12px;
    margin-left: 8px;
}

.acts-recent-list { list-style: none; padding: 0; margin: 0; }
.acts-recent-list li {
    display: flex; gap: 10px; align-items: center;
    padding: 8px 0; border-bottom: 1px solid #f5f5f5;
}
.acts-recent-list li:last-child { border-bottom: none; }

.acts-empty-state {
    text-align: center; padding: 40px;
    color: #999;
}
.acts-empty-state .dashicons { font-size: 48px; width: 48px; height: 48px; color: #4CAF50; }

.acts-application-list { display: flex; flex-direction: column; gap: 12px; }
.acts-application-card {
    background: #fff; border: 1px solid #e0e0e0;
    border-radius: 10px; padding: 16px;
}
.acts-app-header { display: flex; gap: 12px; align-items: center; margin-bottom: 10px; }
.acts-app-info strong { display: block; }
.acts-app-date { font-size: 12px; color: #999; }
.acts-app-field { font-size: 13px; margin-bottom: 4px; }
.acts-app-actions { display: flex; gap: 8px; margin-top: 12px; }

.acts-level-badge { padding: 3px 10px; border-radius: 6px; font-size: 12px; font-weight: 600; }
.acts-level-1 { background: #E8F5E9; color: #2E7D32; }
.acts-level-2 { background: #E3F2FD; color: #1565C0; }
.acts-level-3 { background: #FFF3E0; color: #E65100; }
.acts-level-4 { background: #F3E5F5; color: #7B1FA2; }
.acts-level-5 { background: #FFF8E1; color: #F57F17; }

.acts-settings-table input[type="number"] { width: 80px; }

/* =========================================================
   반응형
   ======================================================= */
@media (max-width: 768px) {
    .acts-monthly-winners { flex-direction: column; align-items: center; }
    .acts-lb-filters { flex-direction: column; }
    .acts-lb-tabs { overflow-x: auto; }
    .acts-lb-row { padding: 10px 12px; gap: 10px; }
    .acts-lb-avatar img { width: 36px; height: 36px; }
    .acts-lb-score-main { font-size: 15px; }
    .acts-team-detail-grid { grid-template-columns: 1fr; }
    .acts-team-header { flex-direction: column; }
    .acts-team-header-actions { width: 100%; }
    .acts-team-stats-row { flex-direction: column; }
    .acts-team-stat-item { min-width: auto; }
    .acts-form-row { flex-direction: column; gap: 0; }
    .acts-admin-row { flex-direction: column; }
    .acts-stats-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
    .acts-team-grid { grid-template-columns: 1fr; }
    .acts-stats-grid { grid-template-columns: 1fr; }
    .acts-lb-meta { flex-wrap: wrap; }
}
