.invoice-cont {
    padding: 16px;
    overflow-x: auto;
}

/* 초기화 및 공통 */
.dream-invoice-container * {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* 최상위 컨테이너 */
.dream-invoice-container {
    width: 100%;
    min-width: 550px;
    background-color: white;
    border: 1px solid #ccc;
    color: #000;
}

/* 공통 테이블 스타일 */
.dream-invoice-container table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.dream-invoice-container td,
.dream-invoice-container th {
    border: 1px solid #ccc;
    padding: 5px;
    vertical-align: middle;
}

/* 1. 헤더 영역 */
.dream-invoice-header {
    text-align: center;
    padding: 20px 0;
    border: 1px solid #ccc;
    border-bottom: none;
    position: relative;
}

.dream-invoice-header h1 {
    font-size: 32px;
    letter-spacing: 10px;
    color: #333;
}

.dream-invoice-header p {
    font-size: 14px;
    position: absolute;
    top: 4px;
    left: 4px;
    color: #333;
    text-align: left;
}

/* 2. 상단 정보 (수신자/공급자) */
.dream-invoice-top {
    display: flex;
    border: 1px double #ccc;
    border-bottom: none;
}

/* 좌측 수신자 */
.dream-invoice-receiver {
    width: 45%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    border-right: 1px solid #ccc;
    padding: 10px;
    line-height: 2.2;
    font-size: 15px;
}

.dream-invoice-receiver strong {
    font-size: 18px;
    text-decoration: underline;
    margin: 5px 0;
}

/* 우측 공급자 */
.dream-invoice-provider {
    width: 55%;
}

/* 공급자 내부 테이블 스타일 재정의 */
.dream-invoice-provider td {
    border: none;
    border-bottom: 1px solid #ccc;
    border-right: 1px solid #ccc;
    text-align: center;
    padding: 4px;
}

.dream-invoice-provider tr:last-child td {
    border-bottom: none;
}

.dream-invoice-provider td:last-child {
    border-right: none;
}

/* 라벨 컬럼 */
.dream-invoice-label {
    background-color: #fff;
    font-weight: bold;
    width: 80px;
    white-space: nowrap;
}

/* 도장 영역 */
.dream-invoice-stamp-wrap {
    position: relative;
    width: 100%;
    display: flex;
    justify-content: end;
    padding-right: 20px;
}

.dream-invoice-stamp-mark {
    position: absolute;
    top: -5px;
    right: 0;
    z-index: 1;
}

.dream-invoice-stamp-mark img {
    height: 28px;
    object-fit: cover;
}

/* 3. 중간 합계 */
.dream-invoice-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid #ccc;
    border-bottom: none;
    padding: 8px 10px;
    font-weight: bold;
    font-size: 15px;
}

/* 4. 상세 내역 그리드 */
.dream-invoice-grid th {
    padding: 8px 0;
}

.dream-invoice-grid td {
    text-align: center;
    height: 30px;
}

/* 내용 (좌측 정렬) */
.dream-invoice-subject {
    text-align: left !important;
    padding-left: 10px !important;
}

/* 금액 (우측 정렬) */
.dream-invoice-money {
    text-align: right !important;
    padding-right: 10px !important;
}

/* 빈 줄 높이 */
.dream-invoice-empty td {
    height: 200px;
}

/* 하단 합계 행 */
.dream-invoice-total td {
    background-color: #fff;
    font-weight: bold;
    padding: 8px;
}

/* 5. 하단 주의사항 */
.dream-invoice-footer {
    border: 1px solid #ccc;
    border-top: none;
    padding: 15px;
    font-size: 12px;
    color: #333;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.dream-invoice-footer>div {
    display: flex;
}

.dream-invoice-footer span {
    margin-right: 5px;
}

.btn_group {
    margin-top: 16px;
}

.btn_group .btn_default {
    font-size: 18px;
    padding: 12px 24px;
}