/* 기본 설정 */
:root{
    --nb-bg: #101828;      /* 배경 */
    --nb-fg: #ffffff;      /* 글자 */
    --nb-link: #c7d2fe;    /* 링크 */
    --nb-height: 44px;     /* 높이 */
    --nb-z: 9999;          /* z-index */
    /* Brand / Primary (로그인 화면과 연결되는 블루 계열) */
    --primary-900:#0B2A6F;
    --primary-700:#1D4ED8;
    --primary-500:#2E7BFF;
    --primary-200:#BFD9FF;
    --primary-100:#EAF3FF;

    /* Accent (돈/성과 포인트: “금색”을 과하게 쓰면 촌스러워져서 ‘살짝’만) */
    --accent-600:#F59E0B; /* 버튼/뱃지 정도 */
    --accent-200:#FFE6B3;

    /* Neutral (정갈함의 핵심) */
    --bg:#F6FAFF;
    --surface:rgba(255,255,255,.88);
    --surface-solid:#FFFFFF;
    --text:#0B1220;
    --muted:#64748B;
    --border:rgba(2, 10, 30, .12);

    /* Status */
    --success:#16A34A;
    --danger:#DC2626;

    /* Shadow */
    --shadow-lg: 0 18px 55px rgba(2, 10, 30, .18);
    --shadow-md: 0 10px 24px rgba(2, 10, 30, .12);

    /* Radius */
    --r-lg:16px;
    --r-md:12px;

    --bnm-z: 10000;
    --bnm-backdrop: rgba(0,0,0,.5);
    --bnm-bg: #fff;
    --bnm-fg: #000;
    --bnm-accent: #3b82f6;
    --bnm-radius: 14px;
    --bnm-shadow: 0 20px 60px rgba(0,0,0,.25);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
html {
    width: 100%;
    height: 100vh;
}

@font-face {
    font-family: 'Pretendard';  /* 1. 앞으로 사용할 폰트 이름 정의 */
    src: url('/fonts/Pretendard-SemiBold.subset.woff') format('woff'); /* 2. 파일 경로 */
    font-weight: 500; /* 3. Medium 굵기는 보통 500으로 지정합니다 */
    font-style: normal;
    font-display: swap; /* 4. 폰트 로딩 전 시스템 폰트를 먼저 보여줌 (깜빡임 방지) */
}
body {
    margin:0;
    min-height:100vh;

    background: #FFF !important;

    background-attachment: fixed;
    background-repeat:no-repeat;
}
::-webkit-scrollbar {
    height: 4px; /* 가로 스크롤바 높이 */
    width: 4px;
}
/* 2. 스크롤바 막대 (움직이는 부분) */
::-webkit-scrollbar-thumb {
    background-color: #888; /* 막대 색상 */
    border-radius: 5px;    /* 막대 둥글게 */
}

/* 3. 스크롤바 뒷배경 (레일) */
::-webkit-scrollbar-track {
    background-color: #f1f1f1; /* 배경 색상 */
}

/* 마우스 올렸을 때 막대 색상 변경 */
::-webkit-scrollbar-thumb:hover {
    background-color: #ccc;
}
h2{
    font-size: 1rem;
}
.menu-title{
    font-size:1.8rem !important;
}
.menu-title1{
    font-size:1.2rem !important;
}
input[type="search"] {
    padding-right: 0.5em; /* X 버튼과 텍스트 간 여유 공간 */
}
input[type="file"] {
    width: 200px; /* X 버튼과 텍스트 간 여유 공간 */
}
.menu-title2{
    font-size:0.8rem !important;
    color: #333;
}
.navbar{
    max-width: 920px;
    margin: auto;
    background: #fff;
    border: 1px solid #CCCCCC;
    border-radius: 5px;
}
.container {
    max-width: 920px;
    margin: 0 auto;
    padding: 10px;
}
header .search-table{
    font-family:'Pretendard', sans-serif;
    max-width: 920px;
    background: #fff;
    border: 1px solid #CCCCCC;

}
main {
    background: #fff;
    font-family:'Pretendard', sans-serif;
    overflow-y: auto;
    position: fixed;
    bottom: 0;
    top: 5px;  /* 화면 최상단에서 10px 떨어지게 함 */
    left: 50%;
    transform: translateX(-50%); /* 좌측에서 10px 떨어지게 함 */
    width: calc(100% - 10px);
    z-index: 999;
    border-radius: 5px;
    max-width: 920px;
    border: 1px solid #F1F5F9;
}
.footer-back-col{
    border-radius: 5px;
}
.move-icon{
    color:darkblue;
}
.border-gray{
    border-bottom: 1px solid grey;
}
/* 헤더 */
.header {
    font-family:'Pretendard', sans-serif;
    position: fixed;
    top: 5px;  /* 화면 최상단에서 10px 떨어지게 함 */
    left: 5px; /* 좌측에서 10px 떨어지게 함 */
    width: calc(100% - 10px);

    color: white;
    text-align: center;
    font-size: 1.5rem;
    font-weight: bold;
    z-index: 1000;
}
.nav-item a{
    text-align: left;
}
/* 푸터 */
.footer {
    font-family:'Pretendard', sans-serif;
    position: fixed;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 10px);
    color: white;
    text-align: center;
    font-size: 1rem;
    z-index: 999;
    max-width: 920px;
    overflow-x: auto;
    background: #fff;
    border: 1px solid #ccc;
}
.btn-delete{
    border: 1px solid black;
    border-radius: 5px;
    padding: 5px 10px 5px 10px;
    background-color: black;
    color: red;

}
.btn-sales-reg{
    width: 30px;
    height: 30px;
    border-radius: 5px;
    background-color: black;
    color: white;
}
.input-price{
    text-align: center;
    padding-top: 5px;
    padding-bottom: 5px;
    border-radius: 5px;
    width: 20%;
    border: 1px solid darkgray;
    font-weight: bold;
}
.btn-deposit, .btn-pursh{
    border: 1px solid black;
    border-radius: 5px;
    padding: 5px 10px 5px 10px;
    background-color: black;
    color: white;
}

.hide{
    display: none   !important;
}

.hide-con{
    display: none;
}

.sales-info1{
    width: 100%;
}

.btn-dark{
    padding: 5px 10px 5px 10px;
    border: 1px solid darkblue !important;
    background: #2d63bd !important;
    min-height: 35px;
    margin-right: 5px;
}
.btn-dark:hover {
    background-color: #333 !important;;
    border-color: #333 !important;;
    color: white !important;;
}
.menu{
    width: 100%;
    text-align: center;
    max-width: 920px;
    margin-top: 5px;
}

menu{
    border-radius: 5px;
    margin-bottom: 5px;
}
table {
    width: 100%;
    border-collapse: collapse; /* 테두리 겹침 방지 */
}
.detail-table {
    width: 100%;
    box-shadow: 0px 2px 5px rgba(0, 0, 0, 0.1);
    display: block;
    border-radius: 8px 8px 8px 8px;
    max-width: 920px;
    margin: auto;
}
.sales-icon{
    margin-left: 5px;
    margin-bottom: 5px;
    background-color: white;
    min-width: 40px;
    min-height: 40px;
}
.company-list-icon {
    background-color: #f9fafb !important;
}
#listContainer{
    max-height: 130px;
    overflow-y: auto;
}

/*검색*/
.search-table {
    width: 100%;
    display: block;
    border-radius:  8px 8px 8px 8px;
    margin:auto;

}
.search-table input, select{
    color: #6c757d;
}
.search-table.hidden {
    display: none;
}
.company-list button{
    border: 1px solid white;
    border-radius: 6px;
    padding: 5px 10px 5px 10px;
    margin-right: 10px;
    margin-bottom:  10px;

}

.company-list{
    overflow-x: auto;
    white-space: nowrap;

}
.search-table .col-md-auto:last-child {
    justify-self: normal;
}
.grid { }
.grid .row { display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 2px;
    width: 100%; /* 전체 화면의 90% 너비 */
    max-width: 920px; /* 최대 너비 */
    padding: 2px;
    border-radius: 8px 8px 8px 8px;
    align-items: center;
    margin:auto;
}
.grid .row5 { display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr;
    gap: 2px;
    width: 100%; /* 전체 화면의 90% 너비 */
    max-width: 920px; /* 최대 너비 */
    padding: 2px;
    border-radius: 8px 8px 8px 8px;
    align-items: center;
    margin:auto;
}
.grid .row1 { display: grid;
    grid-template-columns: repeat(auto-fit, minmax(1fr, 1fr));
    gap: 2px;
    padding: 2px;
    width: 100%; /* 전체 화면의 90% 너비 */
    max-width: 920px; /* 최대 너비 */
    border-radius: 0 0 8px 8px;
    align-items: center;
    margin:auto;
}
.grid .row2{ display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1px;
    padding: 1px;
    width: 100%; /* 전체 화면의 90% 너비 */
    max-width: 920px; /* 최대 너비 */
    align-items: center;
    margin:auto;
    min-width: 0;
}
.grid .row3{ display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 2px;
    width: 100%; /* 전체 화면의 90% 너비 */
    max-width: 920px; /* 최대 너비 */
    align-items: center;
    margin:auto;
    padding: 2px;

}
.w-30{
    width: 30% !important;
}
.w-15{
    width: 15% !important;
}
input.grid-item[inputmode="decimal"], input.grid-item-w-85[inputmode="decimal"]
, input.grid-item-w-30[inputmode="decimal"], input.grid-item-w-50[inputmode="decimal"]
, input.grid-item-w-70[inputmode="decimal"]{
    text-align: right;
    font-weight: 600;
    padding: 5px;
    font-variant-numeric: tabular-nums;
}
input.grid-item[inputmode="decimal"]:focus, input.grid-item-w-85[inputmode="decimal"]:focus
, input.grid-item-w-30[inputmode="decimal"]:focus, input.grid-item-w-50[inputmode="decimal"]:focus
, input.grid-item-w-70[inputmode="decimal"]:focus{
    border-color: #2E7BFF;
    box-shadow: 0 0 0 4px rgba(46,123,255,.18);
}
.grid .row44{ display: grid;
    grid-template-columns: 0.7fr 1fr 0.4fr 1fr;
    gap: 2px;
    padding: 2px;
    width: 100%; /* 전체 화면의 90% 너비 */
    max-width: 920px; /* 최대 너비 */
    align-items: center;
    margin:auto;

}
.grid .row444{ display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr;
    gap: 2px;
    padding: 2px;
    width: 100%; /* 전체 화면의 90% 너비 */
    max-width: 920px; /* 최대 너비 */
    align-items: center;
    margin:auto;

}
.grid .row4-last{ display: grid;
    grid-template-columns: 1fr 1fr 1fr auto;
    gap: 1px;
    padding: 1px;
    width: 100%; /* 전체 화면의 90% 너비 */
    max-width: 920px; /* 최대 너비 */
    align-items: center;
    margin:auto;

}


.grid .row4{ display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2px;
    padding: 2px;
    width: 100%; /* 전체 화면의 90% 너비 */
    max-width: 920px; /* 최대 너비 */
    align-items: center;
    margin:auto;

}

.status-active {
    color: blue;
}
.status-stop {
    color: #a6a6a6;
}
.btn-dark{
    border-radius: 5px;
}
.grid .bottom-border{
    margin-bottom: 1px;
    padding-bottom: 1px;
}
table .bottom-border{
    border-bottom: 2px solid #d5d9e8;

}
.col-md-auto{
    text-align: center;
}
.col-md-auto label{
    color:#333;
}
.grid-item{
    text-align: center;
    padding: 5px 3px;
    border-radius: 5px;
    border: 1px solid darkgray;
    margin: 5px;
    min-width: 50px;

}
.search-table .grid-item{
    max-width: 110px;

}
.detail-table .grid-item{
    max-width: 140px;

}



.grid-item-reg{
    text-align: left;
    padding: 5px 3px;
    border-radius: 5px;
    border: 1px solid darkgray;
    margin-right: 5px;
    margin-bottom: 5px;
    box-sizing: border-box;
    width: 100%;
}
.grid-item-reg[inputmode="decimal"]{
    text-align: right;
    padding: 5px 3px;
    border-radius: 5px;
    border: 1px solid darkgray;
    margin-right: 5px;
    margin-bottom: 5px;
    box-sizing: border-box;
    width: 100%;
}

input[type="date"].grid-item,
input[type="time"].grid-item,
input[type="search"].grid-item,
input[type="search"].grid-item-w-70,
input[type="search"].grid-item-w-50,
input[type="search"].grid-item-w-80,
input[type="search"].grid-item-w-85{
    -webkit-appearance: none; /* 크롬/사파리 검색 전용 스타일 제거 */
    appearance: none;
    background-color: #fff !important;
    padding: 5px;
    border-radius: 5px;
    border: 1px solid darkgray;
}
input[type="date"].grid-item,
input[type="time"].grid-item{
    padding: 5px 0px 5px 0px !important;
}
select.grid-item,
select.grid-item-w-30,
select.grid-item-w-50{
    -webkit-appearance: none; /* 크롬/사파리 검색 전용 스타일 제거 */
    appearance: none;
    background-color: #fff !important;
    text-align: center;
    padding-top: 5px;
    padding-bottom: 5px;
    padding-left: 5px;
    border-radius: 5px;
    border: 1px solid darkgray;
}
.grid-item-title{
    text-align: left;
    padding-top: 5px;
    padding-left: 5px;
    padding-bottom: 5px;
    border-radius: 5px;
    width: 100%;
}
.grid-item-title b{
    color: blue;
}
.grid-item-w-80{
    text-align: center;
    padding-top: 5px;
    padding-bottom: 5px;
    border-radius: 5px;
    border: 1px solid darkgray;
    width: 77%;
}
.grid-item-w-85{
    text-align: center;
    padding-top: 5px;
    padding-bottom: 5px;
    border-radius: 5px;
    border: 1px solid darkgray;
    width: 85%;
}
.grid-item-w-70{
    text-align: center;
    padding-top: 5px;
    padding-bottom: 5px;
    border-radius: 5px;
    border: 1px solid darkgray;
    width: 67%;
}
.grid-item-w-30{
    text-align: center;
    padding-top: 5px;
    padding-bottom: 5px;
    border-radius: 5px;
    border: 1px solid darkgray;
    width: 30%;
}
.grid-item-important{
    font-weight: bold;
}
.grid-item-w-50{
    text-align: center;
    padding-top: 5px;
    padding-bottom: 5px;
    padding-left: 5px;
    border-radius: 5px;
    border: 1px solid darkgray;
    width: 48%;
}
.money{
    text-align: right;
    padding: 5px;
    border-radius: 5px;
    border: 1px solid black;
    width: 50%;
}
.text-red{
    color:red  !important;
}
.text-blue{
    color:blue  !important;
}
.text-gold{
    color:gold  !important;
}
/*검색*/

/*하단*/
.sales-info {
    width: 100%;
    margin: auto;
    border-collapse: collapse;
    color: #fff;
    overflow: hidden;
    table-layout: fixed;
    max-width: 920px;
    border: 1px solid #F1F5F9;
}

.sales-info th, .sales-info td {
    padding: 5px 5px;
    text-align: left;
}

.sales-info th {
    font-weight: bold;
    text-transform: uppercase;
    color:#6d6e6e;
    font-family: 'Pretendard', sans-serif; /* 세련된 폰트 */
}

.sales-info td {
    text-align: right;
    color:black;
    font-weight: bold;
}

.sales-info tr:nth-child(even) {
    background-color: #F9FAFB;
}

.sales-info tr:nth-child(odd) {
    background-color: #ffffff;
}

.sales-info tr:hover {
    background-color: #F1F5F9;
}
/* 공통 버튼 스타일 */
button {
    border-radius: 5px;
    padding: 5px 5px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: 0.2s;
}

/* 1. 메인 버튼 (가장 강조 - 발주 요청/저장) */
.btn-primary {
    background-color: #0064FF; /* 브랜드 컬러 (파랑) */
    color: #FFFFFF; /* 흰색 글자 */
}
.btn-primary:hover {
    background-color: #0056D6; /* 호버 시 약간 어둡게 */
}
.w-35{width:35%!important}
/* 2. 보조 버튼 (새로 추가, 취소) - 배경 없이 테두리만 */
.btn-secondary1 {
    background-color: #9CA3AF;
    border: 1px solid #D1D5DB; /* 연한 회색 테두리 */
    color: #fff; /* 회색 글자 */
    padding-left: 5px;
    padding-right: 5px;
    padding-bottom: 5px;
    padding-top: 5px;
    border-radius: 5px;
    min-width: 50px;
    min-height: 35px;
}
.btn-secondary {
    border: 1px solid #D1D5DB; /* 연한 회색 테두리 */
    color: #fff; /* 회색 글자 */
    border-radius: 5px;
    min-height: 35px;
}
.btn-secondary1:hover {
    background-color: #333;
    border-color: #333;
    color: white;
}


/* 3. 삭제 버튼 (위험한 행동) - 빨간 텍스트 or 연한 빨강 배경 */
.btn-danger {
    background-color: #FFF1F2; /* 아주 연한 빨강 배경 */
    color: #E11D48; /* 빨간 글자 */
}
.btn-danger:hover {
    background-color: #FFE4E6;
}
/* 1. 포인트 강조 (상품명, 총 금액 등 긍정적 정보) */
.text-highlight {
    color: #0064FF !important; /* 쨍한 파란색 (가장 잘 보임) */
    font-weight: 700 !important; /* 굵게 */
}

/* 2. 경고 및 필수 항목 (* 표시, 에러 메시지) */
.text-danger {
    color: #E11D48; /* 너무 촌스럽지 않은 세련된 빨강 */
    font-weight: 500;
}

/* 3. 본문 기본 텍스트 (완전 검정보다 눈이 편함) */
.text-body {
    color: #333333;
}

/* 4. 부가 설명 (날짜, 단위 등 덜 중요한 정보) */
.text-sub {
    color: #888888;
    font-size: 0.9em;
}
/*하단*/
/*리스트*/
.list-con {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 920px;
    margin: auto;
}
.list-con-w-90 {
    display: block;
    flex-direction: column;
    gap: 10px;
    width: 95%;
    margin: auto;
}

.sales-list-table {
    width: 100%;
    border-collapse: collapse;
    color: #ffffff;
    table-layout: auto;
    border: 1px solid #ccc;
}
td[onclick]::after {
    content: " >";
    color: #999;
    font-size: 0.8em;
    margin-left: 5px;
}
td[onclick]:hover::after {
    color: red; /* 마우스 올리면 화살표 색 변경 */
}
th[onclick]::after {
    content: " >";
    color: #999;
    font-size: 0.8em;
    margin-left: 5px;
}
th[onclick]:hover::after {
    color: red; /* 마우스 올리면 화살표 색 변경 */
}

tr[onclick] td:last-child::after {
    content: ' >';
    float: right;
    color: #ccc;
    font-weight: bold;
    margin-left: 5px;
}

tr[onclick]:hover td:last-child::after {
    color: #333; /* 호버 시 색상을 진하게 */
}

tr[onclick] th:last-child::after {
    content: ' >';
    float: right;
    color: #ccc;
    font-weight: bold;
    margin-left: 5px;
}

tr[onclick]:hover th:last-child::after {
    color: #333; /* 호버 시 색상을 진하게 */
}

/* 하단 바 전체 레이아웃 */
/* 하단 바 전체 영역 */
/* 하단 바 전체 레이아웃 및 가로 스크롤 설정 */
/* 🚀 그림자 고정을 위한 Wrapper 설정 */
.bottom-action-wrapper {
    position: relative; /* 그림자의 기준점이 됨 */
    width: 100%;
}

/* 🚀 오른쪽 끝 스크롤 표시 (그라데이션 그림자) */
.bottom-action-wrapper.has-right-shadow::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 14px; /* 그림자 폭 (너무 넓지 않게 조절) */
    height: 100%;

    /* 🚀 수정됨: 배경색 대신 검은색 그림자를 연하게 깔아줍니다 */
    background: linear-gradient(to left, rgba(0, 0, 0, 0.25) 0%, transparent 100%);

    pointer-events: none; /* 클릭 방해 방지 */
}

.bottom-action-bar {
    display: flex;
    justify-content: space-between; /* 화면이 넓을 땐 양끝 배치 */
    align-items: center;
    padding: 5px;
    background-color: #f8f9fa; /* 필요에 따라 색상 변경 */
    border-top: 1px solid #e9ecef;

    /* 가로 스크롤 핵심 속성 */
    overflow-x: auto;
    flex-wrap: nowrap; /* 줄바꿈 방지 */
    gap: 20px; /* 좌측과 우측 버튼 그룹 사이의 여백 */

    /* 스크롤바 숨기기 (기능은 유지) */
}

/* 크롬, 사파리 등 웹킷 기반 브라우저 스크롤바 숨기기 */


/* 좌/우 버튼 그룹: 공간이 좁아져도 찌그러지지 않게 방어 */
.action-left, .action-right {
    display: flex;
    gap: 8px; /* 버튼 간격 */
    flex-shrink: 0;
}

/* 버튼 공통 스타일: 글씨 줄바꿈 및 찌그러짐 완벽 방지 */
.bottom-action-bar button {
    padding: 5px 8px;
    border-radius: 4px;
    font-weight: bold;
    cursor: pointer;
    border: none;

    white-space: nowrap; /* 글씨 개행 방지 */
    flex-shrink: 0;      /* 버튼 축소 방지 */
}
.btn-menu-danger { background-color: #ff4d4f; color: white; }
.btn-menu-secondary { background-color: #e2e8f0; color: #333; }
.btn-menu-outline-primary { background-color: transparent; border: 1px solid #007bff; color: #007bff; }
.btn-menu-primary { background-color: #007bff; color: white; }
.search-table select {
    /* 1. 기본 스타일 제거 (화살표 없애기) */
    -webkit-appearance: none;  /* Chrome, Safari */
    -moz-appearance: none;     /* Firefox */
    appearance: none;          /* Modern Browsers */

    /* 2. 커스텀 화살표 추가 (SVG 아이콘 사용) */
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='gray' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0px center; /* 화살표 위치: 오른쪽 10px, 수직 가운데 */
    background-size: 16px 16px; /* 화살표 크기 */

    /* 3. 박스 디자인 꾸미기 (원하는대로 수정 가능) */
    min-width: 65px !important;;              /* 너비 */
    box-sizing: border-box;
    padding-top: 5px;
    padding-bottom: 5px;
    padding-left: 3px;
    border-radius: 5px;
    border: 1px solid #ccc;            /* 내부 여백 */
    padding-right: 15px;       /* 텍스트가 화살표를 가리지 않게 오른쪽 여백 확보 */
    background-color: #fff;    /* 배경색 */
    outline: none;             /* 포커스 라인 제거 */
    cursor: pointer;
    margin-right: 5px !important;
    margin-left: 5px !important;
    max-height: 32px;
    margin-top: 5px;
}

.detail-table select {
    /* 1. 기본 스타일 제거 (화살표 없애기) */
    -webkit-appearance: none;  /* Chrome, Safari */
    -moz-appearance: none;     /* Firefox */
    appearance: none;          /* Modern Browsers */

    /* 2. 커스텀 화살표 추가 (SVG 아이콘 사용) */
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='gray' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0px center; /* 화살표 위치: 오른쪽 10px, 수직 가운데 */
    background-size: 16px 16px; /* 화살표 크기 */

    /* 3. 박스 디자인 꾸미기 (원하는대로 수정 가능) */
    width: 100%;  /* 텍스트 내용물 크기에 맞춤 */
    min-width: 65px !important;;              /* 너비 */
    box-sizing: border-box;
    padding-top: 5px;
    padding-bottom: 5px;
    padding-left: 3px;
    border-radius: 5px;
    border: 1px solid #ccc;            /* 내부 여백 */
    padding-right: 15px;       /* 텍스트가 화살표를 가리지 않게 오른쪽 여백 확보 */
    background-color: #fff;    /* 배경색 */
    outline: none;             /* 포커스 라인 제거 */
    cursor: pointer;
    margin-right: 5px !important;
    margin-bottom: 5px !important;
}

/* 포커스 되었을 때 스타일 (선택 사항) */
select:focus {
    border-color: #007bff; /* 파란색 테두리 */
}

/* IE 10, 11에서 기본 화살표 숨기기 */
select::-ms-expand {
    display: none;
}

.sales-list-table th, .sales-list-table td {
    padding: 5px;
    text-align: left;
}

.sales-list-table th {
    color: #333; /* 쨍한 파란색 (가장 잘 보임) */
    font-weight: 700;
}
.sales-list-table .title th {
    color: #0064FF; /* 쨍한 파란색 (가장 잘 보임) */
    font-weight: 700;
}
.sign{
    width: 50px;
    height: 50px;
}
.notice-img{
    width: 100%;
}
.fullscreen-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.8); /* 반투명 배경 */
    display: none;
    flex-direction: column; /* 세로 정렬 */
    justify-content: center;
    align-items: center;
    z-index: 1050;
    color: white; /* 텍스트 색상 */
    font-size: 1.5rem; /* 글씨 크기 */
}
.sales-list-table td {
    color: #333;
    font-weight: bold;
}

.sales-list-table tr:last-child td {
    border-bottom: none;
}
.sales-list-table tr:last-child th{
    border-bottom: none;
}
.sales-list-table .text-right {
    text-align: right;
}

.sales-list-table .text-center {
    text-align: center;
}

.sales-list-table tr:hover {
    background-color: red; /* 호버 시 더 밝은 회색 */
}


.sales-list-table tr:nth-child(even) {
    background-color: #F9FAFB;
}

.sales-list-table tr:nth-child(odd) {
    background-color: #F1F5F9;
}
.chart-container{
    background-color: white;
    border-radius: 5px;
}
.sales-list-table .title{
    background-color: white !important;
    border-bottom: 2px solid #d5d9e8;
}
.sales-list-table .title td{
    color:#666 ;
}

.sales-list-table .title-bar{
    border-bottom: 2px solid #d5d9e8;

}
.sales-list-table .title-bar th{
    color:#0064FF ;
    font-weight: bold;
}

.credit-meth {
    background-color: #FEF2F2; /* 파란색 */
    color: #DC2626 !important;
    padding: 4px 8px;
    border-radius: 6px;
    font-weight: 600;
    /* 테두리는 없애거나 아주 연하게 */
    border: none;
    display: inline-block;
}

.card-meth {
    background-color: #EFF6FF; /* 초록색 */
    color: #333 !important;
    padding: 4px 8px;
    border-radius: 6px;
    font-weight: 600;
    /* 테두리는 없애거나 아주 연하게 */
    border: none;
    display: inline-block;
}

.cash-meth {
    background-color: #F3F4F6; /* 주황색 */
    color: #2563EB !important;
    padding: 4px 8px;
    border-radius: 6px;
    font-weight: 600;
    /* 테두리는 없애거나 아주 연하게 */
    border: none;
    display: inline-block;
}
.btn-footer-secondary {
    background-color: #FFFFFF;
    border: 1px solid #0064FF;
    color: #6c757d;
    border-radius: 5px;
    min-height: 35px;
}
.text-small{
    font-size: 0.9em;
}
.btn-search-open {
    background-color: #FFFFFF;
    border: 1px solid #ccc;
    color: #ccc;
    border-radius: 5px;
}
.input-price-sell {
    border: 1px solid #BFDBFE !important; /* 연한 파란 테두리 */
    font-weight: 700 !important;;          /* 굵은 글씨 */
    color: #1E3A8A !important;;            /* 짙은 남색 */
    text-align: right !important;;         /* 오른쪽 정렬 */
    padding-top: 5px !important;;
    padding-bottom: 5px !important;;
    border-radius: 5px !important;;
    width: 100%;
}

/* 원가 입력창 */
.input-price-cost {
    background-color: #F9FAFB; /* 아주 연한 회색 배경 */
    border: 1px solid #E5E7EB;
    color: #6B7280;            /* 회색 글씨 */
    text-align: right;         /* 오른쪽 정렬 */
    padding-top: 5px;
    padding-bottom: 5px;
    border-radius: 5px;
    width: 100%;
}
.hide-product-list {
    display: none;
}
.sales-list-table h2{
    color:black;
}
.sales-list-table.show-products + .hide-product-list {
    display: table;
}
.navbar-toggler-icon {
    width: 24px;
    height: 24px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3E%3Cpath stroke='white' stroke-width='3' d='M4 7h22M4 15h22M4 23h22'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}
.date-btn{
    width: 60px !important;
    color: white;
}
.search-btn
{
    width: 60px;
    background: #2d63bd;
    border: 1px solid darkblue !important;
    height: 35px;
}
.search-btn-w45
{
    width: 50px;
    background: #2d63bd;
    border: 1px solid darkblue !important;
    height: 30px;
}
.search-btn i {
    color: white;
}
.bulk-list{
    width: 97vw !important;
}

.chart-container {
    position: relative;
    width: 100%;     /* 화면 가로 꽉 채우기 */
    height: 260px;   /* 차트 높이는 CSS로 고정 */
}
/*리스트*/

/* 반응형 스타일 */
@media (max-width: 920px) {
    table td, table th {
        font-size: 1rem;  /* 작은 글씨 */
        padding: 2px;
    }

    .search-table {
        font-size: 0.8rem;  /* 작은 글씨 */
        padding: 2px;
    }
    .detail-table {
        font-size: 1rem;  /* 작은 글씨 */
        padding: 2px;
    }
    .list-trade td, .list-trade th, .list-trade-explain td, .list-trade-explain th, .list-trade-explain textarea, .body p{
        font-size: 1rem;
    }
    body {
        font-size: 1rem; /* 작은 화면 기본 폰트 크기 */
    }

    .header {
        font-size: 1rem; /* 헤더와 푸터 크기 축소 */
    }
    .footer {
        font-size: 0.8rem; /* 헤더와 푸터 크기 축소 */
    }
    .footer .bottom-info th, td{
        font-size: 0.9rem !important; /* 헤더와 푸터 크기 축소 */
    }
    h2{
        font-size: 1.1rem;
    }
    .grid-item-title{
        font-size: 1.1rem;
    }
    .menu-title{
        font-size:1.2rem !important;
    }
    .bulk-list{
        width: max-content !important;
    }
    .date-btn {
        width: 45px !important;
    }
    .chart-container {
        height: 340px;   /* 세로를 더 키워서 크게 보이게 */
    }
    .search-btn {
        width: 45px;
    }
    .text-muted {
        font-size: 0.9rem;
    }
}

/* 📲 중간 크기 화면 (태블릿) */
@media (min-width: 601px) and (max-width: 1024px) {
    table td, table th {
        font-size: 1.1rem;  /* 중간 글씨 */
        padding: 8px;
    }
    header .search-table {
        font-size: 1.1rem;  /* 작은 글씨 */
        padding: 8px;
        background: #fff;
    }
    .detail-table {
        font-size: 1.1rem;  /* 작은 글씨 */
        padding: 8px;
    }
    main {
        background: #fff;
    }
    .sales-info th, .sales-info td {
        padding: 5px;
    }
    body {
        font-size: 1.1rem; /* 모바일 기본 폰트 크기 */
    }
    .navbar{
        background: #fff;
    }
    .header {
        font-size: 1.1rem; /* 헤더 폰트 크기 축소 */
    }

    .footer {
        font-size: 1.1rem; /* 푸터 폰트 크기 축소 */
        background: #fff;
    }
    h2{
        font-size: 1.3rem;
    }
    .grid-item-title{
        font-size: 1.3rem;
    }
    #listContainer {
        max-height: 200px;
    }
    .credit-meth{
        padding: 5px 10px;
    }
    .card-meth{
        padding: 5px 10px;
    }
    .cash-meth{
        padding: 5px 10px;
    }
    .bulk-list th{
        font-size: 1.0rem !important;
    }
    .bulk-list td{
        font-size: 1.0rem !important;
    }
    .grid .row {
        grid-template-columns: 1fr 1fr 1fr;
    }
    .grid .row3 {
        grid-template-columns: repeat(auto-fit, minmax(1fr, 1fr));
    }
    .text-muted {
        font-size: 1.1rem;
    }
    .detail-table .grid-item{
        max-width: 170px;
    }
    .search-table .grid-item{
        max-width: 170px;
    }
    .search-table select{
        max-height: 40px;
    }
}

/* 🖥️ 큰 화면 (데스크탑) */
@media (min-width: 1025px) {
    table td, table th {
        font-size: 1.4rem;  /* 기본 글씨 */
    }
    header .search-table {
        font-size: 1.4rem;  /* 작은 글씨 */
        background: #fff;
    }
    .footer{
        background: #fff;
    }
    main{
        background: #fff;
    }
    .detail-table {
        font-size: 1.4rem;  /* 작은 글씨 */
    }
    .grid-item-title{
        font-size: 1.5rem;
    }
    h2{
        font-size: 1.6rem;
    }
    #listContainer {
        max-height: 200px;
    }
    .credit-meth{
        padding: 6px 10px;
    }
    .card-meth{
        padding: 6px 10px;
    }
    .cash-meth{
        padding: 6px 10px;
    }
    .bulk-list th{
        font-size: 1.4rem !important;
    }
    .bulk-list td{
        font-size: 1.4rem !important;
    }
    .grid .row {
        grid-template-columns: 1fr 1fr 1fr;
    }
    .grid .row3 {
        grid-template-columns: repeat(auto-fit, minmax(1fr, 1fr));
    }
    .navbar{
        background: #fff;
    }
    .text-muted {
        font-size: 1.2rem;
    }
    .detail-table .grid-item{
        max-width: 200px;
    }
    .search-table .grid-item{
        max-width: 200px;
    }
    .search-table select{
        max-height: 45px;
    }
}

#notice-bar{
    position: sticky; top: 0; left: 0; right: 0; z-index: var(--nb-z);
    background: var(--nb-bg); color: var(--nb-fg);
    min-height: var(--nb-height); box-sizing: border-box;
}
.notice-wrap{
    max-width: 920px; margin: 0 auto; padding: 8px 16px;
    display: flex; align-items: center; gap: 12px;
}
.notice-text{
    flex: 1; font-size: 14px; line-height: 1.4; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.notice-link{ color: var(--nb-link); text-decoration: underline; margin-left: 8px; }
.notice-link:focus, .notice-close:focus{ outline: 2px solid #94a3b8; outline-offset: 2px; border-radius: 6px; }
.notice-close{
    background: transparent; border: 0; color: var(--nb-fg);
    font-size: 20px; line-height: 1; width: 32px; height: 32px; cursor: pointer;
}
/* 작은 화면에서 두 줄 허용 */
@media (max-width: 640px){
    .notice-text{ white-space: normal; }
}

#notice-modal{ position: fixed; inset: 0; z-index: var(--bnm-z); }
.notice-backdrop{ position:absolute; inset:0; background: var(--bnm-backdrop); }
.notice-dialog{
    position: relative; margin: 0 auto;
    top: 50%; transform: translateY(-50%);
    width: min(560px, calc(100vw - 32px));
    background: var(--bnm-bg); color: var(--bnm-fg);
    border-radius: var(--bnm-radius); box-shadow: var(--bnm-shadow);
    padding: 20px 20px 16px;
    display: flex; flex-direction: column; gap: 14px;
}
.notice-x{
    position:absolute; top:10px; right:10px; width:36px; height:36px;
    border:0; background:transparent; font-size:22px; cursor:pointer; line-height:1;
    border-radius: 10px;
}
.notice-x:focus{ outline: 2px solid #94a3b8; }
.notice-body{ padding: 8px 6px; }
.notice-body h2{ margin: 0 0 8px; font-size: 18px; }
.notice-message{
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 10;    /* 표시 줄 수 */
    overflow: hidden;
    max-height: 16em;        /* 줄높이(line-height:1.6 기준 2줄=3.2em) */
    line-height: 1.6;
}
.notice-link{ color: var(--bnm-accent); text-decoration: underline; }
.notice-actions{ display:flex; gap:10px; justify-content: flex-end; padding-top: 4px; }

.btn-primary{
    background: var(--bnm-accent); color: #fff; border:0; padding:10px 14px;
    border-radius: 10px; cursor:pointer; font-weight:600;
}
.btn-ghost{
    background: transparent; color: #374151; border:1px solid #e5e7eb; padding:10px 14px;
    border-radius: 10px; cursor:pointer;
}
.btn-primary:focus, .btn-ghost:focus{ outline: 2px solid #94a3b8; }

/* 작은 화면 */
@media (max-width: 420px){
    .notice-dialog{ padding: 16px 16px 12px; }
    .notice-actions{ flex-direction: column-reverse; }
    .btn-primary, .btn-ghost{ width: 100%; }
}

/* 모션 최소화 */
@media (prefers-reduced-motion: reduce){
    .notice-dialog{ transition: none; }
}

/* 모달 열릴 때 스크롤 잠금 */
body.notice-lock{ overflow: hidden; }
#notice-value{
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 1;    /* 표시 줄 수 */
    overflow: hidden;
    max-height: 1.6em;        /* 줄높이(line-height:1.6 기준 2줄=3.2em) */
    line-height: 1.6;
}


.recent-wrap { position: relative; display: block; }
.recent-dropdown {
    position: absolute; left: 0; right: 0; z-index: 9999;
    max-height: 240px; overflow-y: auto;
    border: 1px solid #ddd; background: #fff; box-shadow: 0 6px 16px rgba(0,0,0,.08);
    border-radius: 6px; margin-top: 4px; padding: 4px 0;
}
.recent-item {
    padding: 8px 12px; cursor: pointer; display: flex; align-items: center; justify-content: space-between;color: #333;
}
.recent-item:hover, .recent-item.active { background: #f5f7fa; }
.recent-item .text { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.recent-item .del { color: #999; margin-left: 8px; cursor: pointer; }
.recent-header {
    padding: 6px 12px; font-size: 12px; color: #666; display: flex; justify-content: space-between; border-bottom: 1px solid #eee;
}
.recent-clear { color: #666; cursor: pointer; }
