/**
 * 노인일자리 활동 점검 및 관리 시스템 - 시니어 친화형 스타일
 * 기본 20px+, 제목 28px+, 높은 대비, 풀폭 버튼
 */

:root {
    --font-base: 20px;
    --font-title: 28px;
    --font-large: 24px;
    --btn-height: 56px;
    --input-height: 52px;
    --color-submit: #2e7d32;
    --color-submit-hover: #1b5e20;
    --color-end: #1565c0;
    --color-end-hover: #0d47a1;
    --color-danger: #c62828;
    --color-focus: #1565c0;
    --contrast-bg: #fff;
    --contrast-text: #1a1a1a;
    --border-strong: 3px solid #333;
}

* {
    box-sizing: border-box;
}

html {
    font-size: 20px;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: "Malgun Gothic", "Apple SD Gothic Neo", sans-serif;
    font-size: var(--font-base);
    line-height: 1.5;
    color: var(--contrast-text);
    background: #f5f5f5;
    margin: 0;
    padding: 0;
    min-height: 100vh;
}

/* 관리자 영역: 제출 현황과 동일한 넓이 (참여자 체크리스트 페이지 제외) */
body.admin-area .container {
    max-width: 1600px;
}

/* 로그인 */
.login-wrap {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.login-card {
    width: 100%;
    max-width: 420px;
    background: var(--contrast-bg);
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    padding: 32px;
    border: var(--border-strong);
}

.login-card h2 {
    font-size: var(--font-title);
    margin: 0 0 8px 0;
    text-align: center;
}

.login-card .subtitle {
    text-align: center;
    color: #444;
    margin-bottom: 24px;
    font-size: var(--font-large);
}

.login-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
}

.login-tab {
    flex: 1;
    padding: 14px 8px;
    font-size: var(--font-base);
    border: 2px solid #666;
    background: #eee;
    cursor: pointer;
    border-radius: 8px;
}

.login-tab.active {
    background: var(--color-end);
    color: #fff;
    border-color: var(--color-end);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* 폼 공통 */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-size: var(--font-base);
    font-weight: bold;
    margin-bottom: 8px;
    color: var(--contrast-text);
}

.form-control {
    width: 100%;
    padding: 14px 16px;
    font-size: var(--font-base);
    min-height: var(--input-height);
    border: var(--border-strong);
    border-radius: 8px;
    background: #fff;
}

.form-control:focus {
    outline: none;
    border-color: var(--color-focus);
    box-shadow: 0 0 0 3px rgba(21, 101, 192, 0.3);
}

/* 버튼 - 풀폭, 큰 높이 */
.btn {
    display: inline-block;
    width: 100%;
    padding: 16px 24px;
    font-size: var(--font-base);
    font-weight: bold;
    min-height: var(--btn-height);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    text-align: center;
    text-decoration: none;
    transition: background 0.2s;
}

.btn-block {
    width: 100%;
    margin-top: 8px;
}

/* 확인/제출 = 녹색 */
.btn-submit, .btn-success {
    background: var(--color-submit);
    color: #fff;
}

.btn-submit:hover, .btn-success:hover {
    background: var(--color-submit-hover);
}

/* 종료/마감 = 파란 */
.btn-end, .btn-primary {
    background: var(--color-end);
    color: #fff;
}

.btn-end:hover, .btn-primary:hover {
    background: var(--color-end-hover);
}

/* 관리자 로그인 등 */
.btn-secondary {
    background: #455a64;
    color: #fff;
}

.btn-secondary:hover {
    background: #37474f;
}

/* 위험 = 빨간 */
.btn-danger {
    background: var(--color-danger);
    color: #fff;
}

.btn-danger:hover {
    background: #b71c1c;
}

.btn-sm {
    min-height: 44px;
    padding: 10px 16px;
    font-size: 18px;
    width: auto;
}

/* 컨테이너 */
.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 20px;
    padding-bottom: 60px;
}

.page-title {
    font-size: var(--font-title);
    margin: 0 0 8px 0;
}

.page-subtitle {
    color: #444;
    margin-bottom: 24px;
    font-size: var(--font-large);
}

/* 네비게이션 */
.nav {
    overflow-x: auto;
    margin-bottom: 24px;
    -webkit-overflow-scrolling: touch;
}
.nav-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: nowrap;
    gap: 10px;
    min-width: max-content;
}

.nav-list .nav-link {
    display: block;
    padding: 14px 18px;
    font-size: var(--font-base);
    background: #fff;
    border: 2px solid #333;
    border-radius: 8px;
    color: var(--contrast-text);
    text-decoration: none;
}

.nav-list .nav-link:hover,
.nav-list .nav-link.active {
    background: var(--color-end);
    color: #fff;
    border-color: var(--color-end);
}

/* 카드 */
.card {
    background: #fff;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
    border: 2px solid #ddd;
}

.card h2 {
    font-size: var(--font-title);
    margin: 0 0 20px 0;
}

/* 테이블 */
.table-wrap {
    overflow-x: auto;
}

table.table {
    width: 100%;
    border-collapse: collapse;
    font-size: var(--font-base);
}

table.table th,
table.table td {
    padding: 14px 12px;
    border: 1px solid #333;
    text-align: left;
}

table.table th {
    background: #e0e0e0;
    font-weight: bold;
}

/* 체크리스트 항목 (참여자/대상자) */
.checklist-item {
    margin-bottom: 20px;
    padding: 16px;
    border: 2px solid #333;
    border-radius: 8px;
    background: #fafafa;
}

.checklist-item label {
    font-size: var(--font-base);
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
}

.checklist-item input[type="checkbox"],
.checklist-item input[type="radio"] {
    width: 24px;
    height: 24px;
    accent-color: var(--color-submit);
}

/* 알림 */
.alert {
    padding: 16px 20px;
    margin-bottom: 20px;
    border-radius: 8px;
    font-size: var(--font-base);
    border: 2px solid;
}

.alert-danger {
    background: #ffebee;
    border-color: var(--color-danger);
    color: #6d1b1b;
}

.alert-success {
    background: #e8f5e9;
    border-color: var(--color-submit);
    color: #1b5e20;
}

.alert-info {
    background: #e3f2fd;
    border-color: var(--color-end);
    color: #0d47a1;
}

/* 대상자 동적 폼 */
.recipient-block {
    background: #e8f4fd;
    border: 3px solid var(--color-end);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
}

.recipient-block h3 {
    font-size: var(--font-large);
    margin: 0 0 16px 0;
}

.next-recipient-msg {
    font-size: var(--font-large);
    font-weight: bold;
    color: var(--color-end);
    margin: 20px 0;
    text-align: center;
}

/* 인쇄 시 숨김 */
@media print {
    .no-print,
    .nav-list,
    .btn {
        display: none !important;
    }
    body { font-size: 14px; }
    .container { max-width: 100%; }
}

/* ===== 관리자 네비게이션 확장 ===== */
.nav { overflow-x: auto; margin-bottom: 24px; -webkit-overflow-scrolling: touch; }
.nav-list { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: nowrap; gap: 8px; min-width: max-content; }
.nav-list .nav-link { display: block; padding: 10px 14px; font-size: 17px; background: #fff; border: 2px solid #333; border-radius: 8px; color: var(--contrast-text); text-decoration: none; white-space: nowrap; }
.nav-list .nav-link:hover, .nav-list .nav-link.active { background: var(--color-end); color: #fff; border-color: var(--color-end); }

/* ===== 관리자 대시보드 디자인 ===== */

/* 대시보드 헤더 */
.admin-dashboard-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 20px;
    gap: 16px;
}
.admin-dashboard-header h1 {
    font-size: 26px;
    font-weight: 700;
    margin: 0 0 4px 0;
    color: #1a1a1a;
}
.admin-dashboard-header p {
    font-size: 14px;
    color: #666;
    margin: 0;
}
.admin-date-badge {
    text-align: right;
    flex-shrink: 0;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    padding: 10px 18px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}
.admin-date-badge .date-day {
    display: block;
    font-size: 32px;
    font-weight: 700;
    color: #1565c0;
    line-height: 1;
}
.admin-date-badge .date-month {
    display: block;
    font-size: 13px;
    color: #888;
    margin-top: 2px;
}

/* 관리자 상단 내비게이션 바 */
.admin-topnav {
    background: #1a2744;
    border-radius: 10px;
    margin-bottom: 20px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
.admin-topnav .nav-list {
    display: flex;
    flex-wrap: nowrap;
    gap: 0;
    min-width: max-content;
    padding: 0 4px;
    list-style: none;
    margin: 0;
}
.admin-topnav .nav-link {
    display: block;
    padding: 13px 16px;
    font-size: 14px;
    font-weight: 500;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    white-space: nowrap;
    border-radius: 0;
    transition: color 0.15s, background 0.15s, border-bottom-color 0.15s;
}
.admin-topnav .nav-link:hover {
    color: #fff;
    background: rgba(255,255,255,0.08);
    border-bottom-color: transparent;
}
.admin-topnav .nav-link.active {
    color: #fff;
    background: rgba(255,255,255,0.12);
    border-bottom-color: #64b5f6;
}

/* 대시보드 알림 배너 */
.dashboard-alert {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px 20px;
    border-radius: 10px;
    margin-bottom: 14px;
    font-size: 15px;
    border: 1px solid transparent;
}
.dashboard-alert .da-icon { font-size: 20px; flex-shrink: 0; margin-top: 1px; }
.dashboard-alert .da-body { flex: 1; line-height: 1.5; }
.dashboard-alert .da-body a { font-weight: 600; margin-left: 8px; }
.dashboard-alert-success { background: #f0faf2; border-color: #a5d6a7; color: #2e7d32; }
.dashboard-alert-success a { color: #1b5e20; }
.dashboard-alert-warning { background: #fff8e1; border-color: #ffe082; color: #e65100; }
.dashboard-alert-warning a { color: #c62828; }
.dashboard-alert-danger  { background: #fdecea; border-color: #ef9a9a; color: #b71c1c; }
.dashboard-alert-danger a { color: #b71c1c; }
.dashboard-alert-urgent  { background: #fff0f0; border-color: #e57373; color: #c62828; }
.dashboard-alert-urgent a { color: #b71c1c; text-decoration: underline; }

/* KPI 통계 카드 그리드 */
.stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px;
    margin-bottom: 20px;
}
.stat-card {
    background: #fff;
    border-radius: 10px;
    padding: 18px 20px;
    border: 1px solid #e8e8e8;
    border-left: 5px solid #ccc;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
    transition: box-shadow 0.2s, transform 0.2s;
}
.stat-card:hover { box-shadow: 0 4px 14px rgba(0,0,0,0.1); transform: translateY(-2px); }
.stat-card.stat-blue  { border-left-color: #1565c0; }
.stat-card.stat-green { border-left-color: #2e7d32; }
.stat-card.stat-teal  { border-left-color: #00796b; }
.stat-card.stat-gray  { border-left-color: #546e7a; }
.stat-card.stat-danger { border-left-color: #c62828; background: #fff5f5; }

.stat-card .stat-label {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #888;
    margin-bottom: 8px;
}
.stat-card .stat-value {
    font-size: 40px;
    font-weight: 700;
    line-height: 1;
    color: #1a1a1a;
    margin-bottom: 6px;
}
.stat-card.stat-blue   .stat-value { color: #1565c0; }
.stat-card.stat-green  .stat-value { color: #2e7d32; }
.stat-card.stat-teal   .stat-value { color: #00796b; }
.stat-card.stat-danger .stat-value { color: #c62828; }

.stat-card .stat-sub {
    font-size: 13px;
    color: #888;
}
.stat-card .stat-rate {
    font-weight: 700;
    color: #1565c0;
}
.stat-bar-wrap {
    margin-top: 10px;
    height: 4px;
    background: #e8eef4;
    border-radius: 2px;
    overflow: hidden;
}
.stat-bar {
    height: 100%;
    background: #1565c0;
    border-radius: 2px;
    transition: width 0.5s ease;
}

/* 섹션 타이틀 */
.section-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #999;
    margin-bottom: 12px;
}

/* 대시보드 섹션 */
.dashboard-section {
    background: #fff;
    border-radius: 10px;
    padding: 20px 22px;
    margin-bottom: 20px;
    border: 1px solid #e8e8e8;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}

/* 빠른 바로가기 그리드 */
.quicklink-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
    gap: 10px;
}
.quicklink-card {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 16px 18px;
    border-radius: 8px;
    text-decoration: none;
    border: 1px solid transparent;
    transition: all 0.18s ease;
}
.quicklink-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(0,0,0,0.1);
}
.quicklink-card .ql-icon { font-size: 22px; margin-bottom: 4px; }
.quicklink-card .ql-label { font-size: 15px; font-weight: 600; color: #1a1a1a; }
.quicklink-card .ql-desc { font-size: 12px; color: #888; }

.quicklink-card.ql-primary {
    background: #e8f5e9;
    border-color: #c8e6c9;
}
.quicklink-card.ql-primary:hover { background: #d0eedc; border-color: #a5d6a7; }
.quicklink-card.ql-primary .ql-label { color: #2e7d32; }

.quicklink-card.ql-blue {
    background: #e3f0ff;
    border-color: #c5d9f0;
}
.quicklink-card.ql-blue:hover { background: #cde0f8; border-color: #90b9e8; }
.quicklink-card.ql-blue .ql-label { color: #1565c0; }

.quicklink-card.ql-gray {
    background: #f5f5f5;
    border-color: #e0e0e0;
}
.quicklink-card.ql-gray:hover { background: #ebebeb; border-color: #bdbdbd; }
.quicklink-card.ql-gray .ql-label { color: #455a64; }

@media (max-width: 768px) {
    .admin-dashboard-header { flex-direction: column; }
    .admin-date-badge { text-align: left; display: flex; align-items: center; gap: 10px; padding: 8px 14px; }
    .admin-date-badge .date-day { font-size: 22px; }
    .stat-grid { grid-template-columns: repeat(2, 1fr); }
    .quicklink-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ===== 참여자 대시보드 ===== */

/* 인사말 히어로 카드 */
.participant-hero {
    background: linear-gradient(135deg, #1565c0 0%, #1e88e5 100%);
    color: #fff;
    border-radius: 16px;
    padding: 28px 24px 22px;
    margin-bottom: 16px;
    box-shadow: 0 6px 20px rgba(21,101,192,0.28);
}
.hero-greeting {
    font-size: 24px;
    opacity: 0.82;
    margin: 0 0 6px;
}
.participant-hero h1.hero-name {
    font-size: 34px;
    font-weight: 800;
    margin: 0 0 12px;
    line-height: 1.1;
    color: #fff;
}
.hero-meta {
    font-size: 17px;
    opacity: 0.88;
    margin-bottom: 16px;
    display: flex;
    flex-wrap: wrap;
    gap: 4px 8px;
    align-items: center;
}
.hero-sep { opacity: 0.4; }
.hero-job { font-weight: 600; }
.hero-device {
    font-size: 12px;
    opacity: 0.5;
    margin: 0;
    font-family: monospace;
    letter-spacing: 0.3px;
}

/* 오늘 상태 카드 */
.today-status-card {
    background: #fff;
    border-radius: 14px;
    padding: 20px 22px;
    margin-bottom: 16px;
    border: 1px solid #e8e8e8;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
}
.status-row {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 4px 0;
}
.status-icon-wrap {
    width: 54px;
    height: 54px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    flex-shrink: 0;
}
.status-icon-wrap.status-ok      { background: #e8f5e9; }
.status-icon-wrap.status-pending  { background: #fff8e1; }
.status-icon-wrap.status-blue     { background: #e3f0ff; }
.status-info { flex: 1; }
.status-label { font-size: 14px; color: #999; margin: 0 0 3px; }
.status-value { font-size: 26px; font-weight: 700; margin: 0; color: #1a1a1a; }
.status-value.ok      { color: #2e7d32; }
.status-value.pending { color: #e65100; }
.status-value.blue    { color: #1565c0; }
.status-divider { height: 1px; background: #f2f2f2; margin: 14px 0; }
.next-submit-note { font-size: 13px; color: #bbb; margin: 14px 0 0; }

/* 액션 영역 */
.participant-actions { margin-bottom: 14px; }
.action-msg {
    font-size: 19px;
    color: #555;
    margin: 0 0 14px;
    font-weight: 500;
}
.participant-actions .btn { margin-bottom: 10px; }

/* 푸터 로그아웃 */
.participant-footer { margin-top: 4px; }
.btn-logout {
    background: transparent !important;
    color: #aaa !important;
    border: 1px solid #ddd !important;
    font-size: 16px !important;
    min-height: 44px !important;
    padding: 10px 24px !important;
    width: auto !important;
    box-shadow: none !important;
}
.btn-logout:hover {
    background: #f5f5f5 !important;
    color: #666 !important;
}

/* 공지사항 팝업 */
.notice-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.55);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
}
.notice-modal {
    background: #fff;
    border-radius: 18px;
    max-width: 440px;
    width: 100%;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 24px 64px rgba(0,0,0,0.22);
    overflow: hidden;
}
.notice-modal-header {
    background: linear-gradient(135deg, #1565c0 0%, #1e88e5 100%);
    color: #fff;
    padding: 22px 24px 18px;
    flex-shrink: 0;
}
.notice-modal-header h2 { font-size: 22px; margin: 0 0 4px; color: #fff; }
.notice-modal-header p  { font-size: 14px; opacity: 0.8; margin: 0; }
.notice-modal-body { padding: 20px 24px; overflow-y: auto; flex: 1; }
.notice-item { padding: 16px 0; border-bottom: 1px solid #f0f0f0; }
.notice-item:last-child  { border-bottom: none; }
.notice-item:first-child { padding-top: 0; }
.notice-item-title   { font-size: 20px; font-weight: 700; margin: 0 0 8px; color: #1a1a1a; }
.notice-item-content { font-size: 19px; line-height: 1.7; margin: 0; color: #333; white-space: pre-wrap; }
.notice-modal-footer {
    padding: 16px 24px;
    flex-shrink: 0;
    border-top: 1px solid #eee;
}
.notice-modal-footer .btn { margin: 0; font-size: 20px; min-height: 58px; }

/* ===== 로그인 페이지 개선 ===== */
.login-card {
    border: 1px solid #e0e0e0!important;
    box-shadow: 0 8px 32px rgba(0,0,0,0.10)!important;
}
.login-card h2 { color: #1565c0; }
.login-card .subtitle { color: #777; font-size: 17px; }
.login-tabs {
    background: #f0f4f8;
    border-radius: 10px;
    padding: 4px;
    gap: 4px!important;
    margin-bottom: 24px;
}
.login-tab {
    background: transparent!important;
    border: none!important;
    border-radius: 8px!important;
    color: #666!important;
    font-size: 18px!important;
    padding: 12px 8px!important;
    transition: all 0.2s!important;
}
.login-tab.active {
    background: #fff!important;
    color: #1565c0!important;
    font-weight: 700!important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.10)!important;
}

/* ===== 정산 테이블 ===== */
.payroll-table th, .payroll-table td { padding: 10px 8px; font-size: 17px; }

/* ===== muted 텍스트 ===== */
.muted { color: #666; font-size: 16px; margin-bottom: 12px; }

/* ===== 반응형 ===== */
@media (max-width: 600px) {
    .container { padding: 12px; }
    .login-card { padding: 20px; }
    .card { padding: 16px; }
    table.table th, table.table td { padding: 10px 8px; font-size: 18px; }
}

