/* static/style.css (브랜딩 2차 수정본) */

/* 1. 전체 페이지 기본 설정 */
* {
    box-sizing: border-box;
}

body {
    /* ⭐️ 폰트 변경: Pretendard */
    font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
    /* ⭐️ 배경색 변경: 연한 크림색 */
    background-color: #FAF8F5; 
    /* ⭐️ 기본 글자 색 변경: 진한 브라운 */
    color: #3D352E;
    margin: 0;
    padding: 0;
    display: grid;
    place-items: center;
    min-height: 100vh;
}

/* 2. 헤더 (대시보드, 관리자용) */
header {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    /* ⭐️ 테두리색 변경: 연한 브라운 */
    border-bottom: 2px solid #DCD3C9;
    padding: 15px 30px;
    background: #ffffff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    position: fixed;
    top: 0;
    left: 0;
    z-index: 100;
}

/* ⭐️ 헤더 로고 이미지 크기 설정 (수정됨!) */
header .logo img {
    height: 24px;  /* ⭐️ 0x0 방지를 위해 'max-height'를 'height'로 변경 */
    width: auto;   /* 비율 유지를 위해 auto */
    display: block;/* 이미지 렌더링을 돕기 위한 속성 */
}

header .user-welcome {
    font-size: 1.1em;
    font-weight: 500; /* 폰트 굵기 조정 */
}

/* ⭐️ 헤더 로그아웃 버튼 */
header a {
    text-decoration: none;
    /* ⭐️ 메인 컬러 적용 */
    color: #5C4939;
    font-weight: 600;
    font-size: 0.9em;
    border: 2px solid #5C4939;
    padding: 5px 10px;
    border-radius: 20px;
    transition: all 0.3s ease;
}
header a:hover {
    background-color: #5C4939;
    color: white;
}

/* 3. 메인 컨텐츠 영역 (대시보드, 관리자용) */
.container {
    width: 100%;
    max-width: 1400px;
    padding: 20px;
    margin-top: 80px; /* 고정된 헤더 높이만큼 밀어내기 */
    display: block;
}

/* 4. 로그인 페이지 전용 */
.login-container {
    width: 100%;
    display: grid;
    place-items: center;
    padding: 20px;
}

.login-box {
    background: #fff;
    /* ⭐️ 테두리색 변경 */
    border: 2px solid #DCD3C9;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.08);
    width: 100%;
    max-width: 450px;
}

/* ⭐️ 로그인 로고 이미지 크기 설정 */
.login-box .logo {
    text-align: center;
    margin-bottom: 30px;
}
.login-box .logo img {
    max-height: 48px; /* 로그인 로고 높이 */
    width: auto;
}

.login-box .footer {
    text-align: center;
    margin-top: 30px;
    font-size: 0.9em;
    color: #aaa;
}

/* 5. 공통 카드 (박스) 디자인 */
.card {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 16px;
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}
.card h2 {
    margin-top: 0;
    /* ⭐️ 메인 컬러 적용 */
    border-bottom: 2px solid #DCD3C9;
    padding-bottom: 10px;
    color: #5C4939;
    font-weight: 700;
}

/* 6. 폼 요소 (input, button 등) */
.form-group {
    margin-bottom: 20px;
}
.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 1.1em;
}
.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 10px;
    font-family: 'Pretendard', sans-serif; /* 폰트 적용 */
    font-size: 1em;
    transition: border-color 0.3s ease;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    /* ⭐️ 메인 컬러 적용 */
    border-color: #5C4939;
    outline: none;
}
.form-group textarea {
    min-height: 100px;
}

/* ⭐️ 공통 버튼 (메인 컬러 적용) */
button,
.filter-btn {
    width: 100%;
    padding: 14px;
    background: #5C4939; /* 메인 컬러 */
    color: white;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-size: 1.1em;
    font-weight: 600;
    font-family: 'Pretendard', sans-serif;
    transition: all 0.3s ease;
    box-shadow: 0 4px 8px rgba(92, 73, 57, 0.3); /* 메인 컬러 그림자 */
}
button:hover,
.filter-btn:hover {
    transform: translateY(-2px);
    background-color: #4a3b2d; /* 더 진한 브라운 */
    box-shadow: 0 6px 12px rgba(92, 73, 57, 0.5);
}

/* ⭐️ CSV 버튼 (구분을 위해 다른 색 유지) */
.csv-btn {
    background: #4ECDC4; /* 청록색 */
    box-shadow: 0 4px 8px rgba(78, 205, 196, 0.3);
}
.csv-btn:hover {
    background-color: #40b3aa;
    box-shadow: 0 6px 12px rgba(78, 205, 196, 0.5);
}

/* 7. 테이블 디자인 (내역, 관리자) */
.history-table,
.request-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 8px;
    margin-top: 15px;
}
.history-table th,
.request-table th {
    background-color: #FAF8F5; /* 배경색 */
    padding: 12px;
    text-align: left;
    font-size: 1em;
    font-weight: 700;
    color: #5C4939; /* 메인 컬러 */
    border-bottom: 2px solid #DCD3C9; /* 연한 브라운 */
}
.history-table td,
.request-table td {
    background: #fff;
    border: 1px solid #f0f0f0;
    padding: 14px;
    font-size: 1em;
    font-weight: 500;
}
.history-table tr td:first-child,
.request-table tr td:first-child { border-radius: 10px 0 0 10px; }
.history-table tr td:last-child,
.request-table tr td:last-child { border-radius: 0 10px 10px 0; }
.history-table tr:hover td,
.request-table tr:hover td {
    background-color: #FAF8F5;
}

.center { text-align: center; }

/* 8. 상태 태그 (파스텔톤 유지) */
.status {
    font-weight: 600;
    padding: 6px 10px;
    border-radius: 20px;
    font-size: 0.9em;
}
.status-pending { color: #856404; background-color: #FFF3CD; border: 1px solid #FFEBA8; }
.status-approved { color: #155724; background-color: #D4EDDA; border: 1px solid #C3E6CB; }
.status-rejected { color: #721C24; background-color: #F8D7DA; border: 1px solid #F5C6CB; }
.status-cancelled { color: #495057; background-color: #E2E3E5; border: 1px solid #D6D8DB; text-decoration: line-through; }

/* 9. 관리자 필터 폼 */
.filter-form {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: flex-end;
    margin-bottom: 20px;
}
.filter-group { flex: 1; min-width: 150px; }
.filter-group label { font-size: 0.9em; color: #555; }
.filter-group input, .filter-group select {
    padding: 10px;
    font-size: 1em;
}

.filter-btn,
.csv-btn {
    width: auto;
    padding: 10px 18px;
    font-size: 1em;
    flex-grow: 0;
}
.action-btn {
    padding: 6px 12px;
    border: none;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9em;
    font-family: 'Pretendard', sans-serif;
}
.btn-approve { background-color: #28a745; }
.btn-reject { background-color: #dc3545; }
.cancel-btn {
    background: none;
    border: none;
    color: #dc3545;
    text-decoration: underline;
    font-weight: 600;
    font-size: 1em;
    cursor: pointer;
    font-family: 'Pretendard', sans-serif;
}

/* 10. Flash 메시지 */
.flash-messages {
    width: 100%;
    max-width: 1400px;
    padding: 0 20px;
    margin-top: 90px;
    position: absolute;
    top: 0;
}
.flash-message {
    padding: 15px 20px;
    margin-bottom: 15px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 1.1em;
    border-width: 2px;
    border-style: solid;
}
.flash-success { background-color: #D4EDDA; color: #155724; border-color: #C3E6CB; }
.flash-error { background-color: #F8D7DA; color: #721C24; border-color: #F5C6CB; }

/* 11. 대시보드 - 연차 현황 */
.pto-info .big-number {
    font-size: 3.5em;
    font-weight: 700;
    /* ⭐️ 메인 컬러 적용 */
    color: #5C4939;
    margin: 10px 0;
}
.pto-info .small-text {
    font-size: 1.2em;
    color: #666;
    margin: 5px 0;
}
.pto-info strong, .user-info strong {
    min-width: 80px;
    display: inline-block;
    color: #333;
    font-weight: 600;
}
.user-info p {
    font-size: 1.2em;
    margin: 10px 0;
}
/* static/style.css 파일 맨 아래에 추가 */

/* 12. 비밀번호 변경 (접기/펼치기) */
.password-change h2 {
    cursor: pointer; /* ⭐️ 마우스를 손가락 모양으로 */
    user-select: none; /* ⭐️ 텍스트가 선택되지 않도록 */
}
.password-change h2 span {
    font-size: 0.8em;
    font-weight: 500;
    color: #888;
    margin-left: 10px;
}

/* 13. Footer (대시보드 / 관리자용) */
.footer-container {
    width: 100%;
    max-width: 1400px; /* 메인 container 너비와 동일하게 */
    padding: 30px 20px 20px 20px;
    margin-top: 30px; /* 메인 컨텐츠와 여백 */
    text-align: center;
    border-top: 2px solid #DCD3C9; /* 헤더와 동일한 구분선 */
}

.footer-container .slogan-img {
    max-height: 12px; /* ⭐️ 이 값을 조절하시면 됩니다! */
    width: auto;
    margin-bottom: 2px;
}

.footer-container .copyright {
    font-size: 0.9em;
    color: #aaa;
    margin-top: 10px;
}