/* index.html */
body {
    margin: 0;
    padding: 0;
    font-family: 'Pretendard'; 
    background-color: #f5f7fa;
    color: #333;
    line-height: 1.6;
}

/* Pretendard 폰트 등록 */
@font-face {
    font-family: 'Pretendard';
    src: url('/static/fonts/Pretendard-Medium.otf') format('opentype');
    font-weight: normal;
    font-style: normal;
}

/* 헤더 스타일 */
.header {
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 90%; /* 기본적으로 창 폭의 90%를 차지 */
    max-width: 1200px; /* 최대 폭 제한 */
    height: auto; /* 높이는 콘텐츠에 따라 조정 */
    background-color: #ffffff;
    color: #000000;
    display: flex;
    align-items: center; /* 세로 중앙 정렬 */
    justify-content: flex-start; /* 로고를 왼쪽에 정렬 */
    flex-wrap: wrap; /* 줄바꿈 허용 */
    padding: 10px 20px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    box-sizing: border-box;
}

/* 제목 스타일 */
.header h1 {
    margin: 0;
    font-size: clamp(14px, 4vw, 20px); /* 제목 글자 크기 자동 조정 */
    text-align: center; /* 텍스트 중앙 정렬 */
    flex: 1; /* 남은 공간을 채우도록 설정 */
    color: #000000;
    white-space: normal; /* 줄바꿈 허용 */
    overflow-wrap: break-word; /* 긴 단어 줄바꿈 */
}

/* 제목 링크 스타일 */
.header h1 a {
    text-decoration: none; /* 밑줄 제거 */
    color: inherit; /* 부모 요소의 색상 상속 */
}

.header h1 a:visited, /* 방문한 링크 */
.header h1 a:active { /* 클릭 중인 링크 */
    color: inherit; /* 부모 요소의 색상 상속 */
    text-decoration: none; /* 밑줄 제거 */
}

/* 호버 효과 (선택 사항) */
.header h1 a:hover {
    cursor: pointer;
}

/* 로고 스타일 */
.index.main-button {
    flex: 0 0 auto; /* 로고는 기본 크기를 유지 */
    margin-right: 10px; /* 로고와 텍스트 간 여백 */
    display: flex;
    align-items: center; /* 로고 세로 중앙 정렬 */
}

.index.main-button img {
    width: 120px; /* 로고 크기 */
    height: auto;
}

/* 반응형 디자인 */
@media (max-width: 768px) {
    .header {
        width: 95%; /* 작은 화면에서는 더 좁게 설정 */
        padding: 10px 15px; /* 내부 여백 조정 */
        align-items: center; /* 세로 중앙 정렬 */
    }

    .header h1 {
        font-size: clamp(12px, 4vw, 18px); /* 제목 글자 크기 자동 조정 */
    }

    .index.main-button img {
        width: 100px; /* 로고 크기 조정 */
    }
}

@media (max-width: 480px) {
    .header {
        flex-direction: column; /* 요소를 세로로 정렬 */
        align-items: center; /* 세로 및 가로 중앙 정렬 */
        text-align: center; /* 텍스트 중앙 정렬 */
    }

    .header h1 {
        order: 2; /* 제목이 로고 아래로 이동 */
        margin-top: 10px;
        font-size: clamp(10px, 4vw, 16px); /* 제목 글자 크기 자동 조정 */
    }

    .index.main-button {
        order: 1; /* 로고가 제목 위로 이동 */
        margin-bottom: 10px; /* 로고와 텍스트 간 여백 추가 */
    }
    .back-button{
        order: 3;
    }
}



strong {
    font-weight: 500;
    color:#133c6d;
}
h1 {
    color: #133c6d;
}

h2 {
    font-weight: 500;
    color: #133c6d;
}

h3 {
    font-weight: 500;
    color: #133c6d;
}

/* 컨텐츠 영역 스타일 */
.form-container {
    margin: 100px auto 50px;
    padding: 20px;
    max-width: 800px;
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    width: 90%; /* 기본적으로 창 폭의 90%를 차지 */
    max-width: 1200px; /* 최대 폭 제한 */
}

.form-container h2 {
    font-size: 24px;
    margin-bottom: 10px;
    color: #133c6d;
    border-bottom: 2px solid #133c6d;
    display: inline-block;
    padding-bottom: 5px;
}

.form-container p {
    margin: 10px 0;
    font-size: 16px;
    text-align: justify;
}

/* 라디오 버튼 스타일 */
.radio-group-horizontal {
    display: flex;
    justify-content: space-around;
    margin: 20px 0;
}

.radio-item {
    text-align: center;
    flex: 1;
    padding: 10px;
}

.description {
    font-size: 14px;
    color: #555;
    margin-top: 5px;
}

/* 버튼 스타일 */
.submit-button {
    background-color: #133c6d;
    color: #ffffff;
    border: none;
    padding: 10px 20px;
    font-size: 18px;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    justify-content: center; /* 가로 중앙 정렬 */
}

.submit-button {
    background-color: #133c6d;
    color: #ffffff;
    border: none;
    padding: 10px 20px;
    font-size: 18px;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    margin: 0 auto; /* 위아래 여백과 좌우 중앙 정렬 */
    display: block; /* 블록 요소 */
}

.submit-button:hover {
    background-color: #000000;
}

/* 필터 폼 스타일 */
.filter-form {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 90%; /* 기본적으로 창 폭의 90%를 차지 */
    max-width: 1200px; /* 최대 폭 제한 */
    padding: 10px;
    margin-left: 20px; /* 화면 좌측에 여백 추가 */
    background-color: #f9f9f9; /* 배경색 추가 */
    border: 1px solid #ddd; /* 테두리 추가 */
    border-radius: 5px;
}

.filter-title {
    margin: 10px 0 5px 0;
    font-size: 16px;
}

.symbol-filter,
.filter-selectors {
    justify-content: space-around;
    /* margin: 20px 0; */
    margin-bottom: 15px;
}

.symbol-filter label,
.selector label {
    font-size: 14px;
    font-weight: normal;
}

.selector {
    margin-bottom: 10px;
}

/* 테이블 스타일 */
table {
    border-collapse: collapse;
    width: 100%;
    margin-top: 20px;
    word-wrap: break-word; 
    table-layout: auto; 
    overflow-wrap: break-word; 
    margin: 0 auto; /* 위아래 여백과 좌우 중앙 정렬 */
    overflow-x: auto;
    max-width: 100%;
    display: block;
    border: none;
}

/* 컬럼명(헤더) 스타일 */
th {
    text-align: center; /* 컬럼명 가운데 정렬 */
    background-color: #f0f0f0;
    font-size: 14px;
    text-align: center;
    background-color: #f0f0f0;
    cursor: pointer;
    white-space: normal; /* 헤더는 줄바꿈 방지 */
    padding: 10px;
    border: 1px solid #ddd;
}

th:hover {
    background-color: #e0e0e0; /* 컬럼명 마우스 오버 시 배경색 변경 */
}

/* 데이터 셀 스타일 */
td {
    text-align: left; /* 기본 데이터 좌측 정렬 */
    white-space: normal; /* 데이터 줄바꿈 허용 */
    font-size: 13px;
    max-width: 150px; /* 각 셀의 최대 너비 설정 */
    overflow-wrap: break-word; /* 긴 텍스트 줄바꿈 */
    word-wrap: break-word; /* 줄바꿈 허용 */
    white-space: normal; /* 텍스트 줄바꿈 */
    padding: 10px;
    border: 1px solid #ddd;
}

/* 특정 열에 추가 스타일 */
td.numeric {
    text-align: right; /* 숫자 데이터는 오른쪽 정렬 */
}

/* 행 강조 */
tr:hover {
    background-color: #f9f9f9;
}

/* 숫자 데이터는 오른쪽 정렬 */
td.numeric {
    font-size: 13px;
    text-align: right;
}

/* 클릭 가능한 행의 스타일 */
.clickable-row {
    cursor: pointer;
}

/* .clickable-row:hover {
    background-color: #f9f9f9;
} */

/* 페이지네이션 스타일 */
.pagination {
    display: flex;
    justify-content: center;
    margin: 10px 0;
}

.pagination a {
    margin: 0 5px;
    text-decoration: none;
    padding: 5px 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    color: #333;
}

.pagination a:hover {
    background-color: #f2f2f2;
}

/* back-button 스타일 확장 */
.back-button {
    /* position: absolute; */
    top: 10px; /* 상단 여백 */
    right: 10px; /* 우측 여백 */
    align-items: center;
}

.trade-history-table {
    border-collapse: collapse;
    width: 100%;
    overflow-x: auto;
    max-width: 100%;
    display: block;
    border: none;
}

.trade-history-table th,
.trade-history-table td {
    padding: 8px;
    text-align: left;
}

.download-button {
    display: inline-block;
    padding: 10px 20px;
    background-color: #133c6d;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-size: 14px;
    text-align: center;
    margin-top: 10px;
    display: block;
    border: none;
}

.download-button:hover {
    background-color: #02142b;
}