* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    min-height: 100%;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans KR", sans-serif;
    background: #f3f6fb;
    color: #1f2937;
}

.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px 16px;
}

.login-card {
    width: 100%;
    max-width: 430px;
    overflow: hidden;
    border-radius: 20px;
    background: #ffffff;
    box-shadow: 0 24px 56px rgba(15, 23, 42, 0.16);
}

.login-header {
    padding: 34px 34px 26px;
    background: linear-gradient(135deg, #102f4f, #1f7a68);
    color: #ffffff;
}

.login-header h1 {
    margin: 0;
    font-size: 27px;
    line-height: 1.2;
    font-weight: 850;
    letter-spacing: -0.04em;
}

.login-header p {
    margin: 11px 0 0;
    color: rgba(255, 255, 255, 0.82);
    font-size: 14px;
}

.login-body {
    padding: 30px 34px 34px;
}

.alert {
    margin-bottom: 18px;
    padding: 12px 14px;
    border-radius: 12px;
    font-size: 14px;
    line-height: 1.45;
}

.alert-error {
    background: #fff1f2;
    color: #be123c;
    border: 1px solid #fecdd3;
}

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    margin-bottom: 7px;
    font-size: 14px;
    font-weight: 750;
    color: #374151;
}

.form-control {
    width: 100%;
    height: 50px;
    padding: 0 14px;
    border: 1px solid #d1d5db;
    border-radius: 12px;
    outline: none;
    font-size: 15px;
    background: #ffffff;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-control:focus {
    border-color: #1f7a68;
    box-shadow: 0 0 0 4px rgba(31, 122, 104, 0.14);
}

.btn-primary {
    width: 100%;
    height: 52px;
    margin-top: 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 13px;
    background: #102f4f;
    color: #ffffff;
    text-decoration: none;
    line-height: 1;
    font-size: 16px;
    font-weight: 850;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.1s ease;
}

.btn-primary:hover {
    background: #0b253f;
    color: #ffffff;
    text-decoration: none;
}

.btn-primary:active {
    transform: translateY(1px);
}

.login-footer {
    margin-top: 20px;
    color: #6b7280;
    text-align: center;
    font-size: 13px;
}

.app-header {
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 28px;
    background: #102f4f;
    color: #ffffff;
}

.app-title {
    font-size: 20px;
    font-weight: 850;
    letter-spacing: -0.03em;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 14px;
}

.header-actions a {
    color: #ffffff;
    text-decoration: none;
    font-weight: 750;
}

.container {
    max-width: 1180px;
    margin: 32px auto;
    padding: 0 20px;
}

.card {
    background: #ffffff;
    border-radius: 18px;
    padding: 28px;
    box-shadow: 0 14px 36px rgba(15, 23, 42, 0.08);
}

.card-title {
    margin: 0 0 14px;
    font-size: 22px;
    font-weight: 850;
    letter-spacing: -0.03em;
}

.info-list {
    margin: 0;
    padding: 0;
    list-style: none;
    color: #4b5563;
    line-height: 1.9;
    font-size: 15px;
}

.info-list strong {
    display: inline-block;
    width: 96px;
    color: #111827;
}

@media (max-width: 520px) {
    .login-header,
    .login-body {
        padding-left: 24px;
        padding-right: 24px;
    }

    .login-header h1 {
        font-size: 24px;
    }

    .app-header {
        height: auto;
        min-height: 64px;
        padding: 16px 20px;
        align-items: flex-start;
        flex-direction: column;
        gap: 8px;
    }
}

/* 로그인 이후 본문 공통 레이아웃 */
.site-header { background:#fff; border-bottom:1px solid #e5e7eb; box-shadow:0 8px 24px rgba(15,23,42,.04); }
.site-header-inner { max-width:1180px; min-height:72px; margin:0 auto; padding:0 24px; display:flex; align-items:center; justify-content:space-between; gap:24px; }
.brand-link { display:inline-flex; align-items:center; gap:12px; color:#1f2937; text-decoration:none; }
.brand-logo { width:40px; height:40px; display:block; border-radius:12px; box-shadow:0 8px 18px rgba(37,99,235,.18); }
.brand-title { font-size:22px; font-weight:850; letter-spacing:-.04em; }
.header-menu { display:flex; align-items:center; gap:12px; color:#4b5563; font-size:14px; }
.header-user-name { padding-right:4px; font-weight:750; color:#111827; }
.header-menu-link { min-height:36px; padding:8px 13px; display:inline-flex; align-items:center; justify-content:center; border:1px solid #d1d5db; border-radius:10px; background:#fff; color:#374151; text-decoration:none; font-weight:750; transition:background .15s ease,border-color .15s ease,color .15s ease; }
.header-menu-link:hover, .header-menu-link.is-active { background:#f3f6fb; border-color:#9ca3af; }
.header-logout-link { border-color:#102f4f; background:#102f4f; color:#fff; }
.header-logout-link:hover { border-color:#0b253f; background:#0b253f; color:#fff; }
.page-container { max-width:1180px; min-height:calc(100vh - 224px); margin:0 auto; padding:32px 20px 52px; }
.card-description { margin:-4px 0 22px; color:#6b7280; line-height:1.65; font-size:14px; }
.dashboard-card, .form-card { max-width:760px; }
.content-form { max-width:460px; }
.alert-success { background:#ecfdf5; color:#047857; border:1px solid #a7f3d0; }
.form-actions { display:flex; align-items:center; gap:10px; margin-top:8px; }
.btn-inline { width:auto; min-width:150px; padding:0 22px; }
.btn-secondary { height:52px; min-width:92px; padding:0 18px; display:inline-flex; align-items:center; justify-content:center; border:1px solid #d1d5db; border-radius:13px; background:#fff; color:#374151; text-decoration:none; font-size:15px; font-weight:800; }
.btn-secondary:hover { background:#f9fafb; }
.site-footer { background:#f7f7f8; border-top:1px solid #d6d6d8; color:#777b82; }
.footer-top-line { width:min(1000px,74vw); height:3px; margin:0 auto; background:#444; }
.site-footer-inner { max-width:1000px; min-height:106px; margin:0 auto; padding:28px 20px 26px; display:flex; align-items:center; justify-content:space-between; gap:36px; }
.footer-brand { display:flex; align-items:center; gap:12px; opacity:.48; }
.footer-logo { width:44px; height:44px; display:block; border-radius:12px; opacity:.72; }
.footer-title { color:#5f6368; font-size:20px; font-weight:850; letter-spacing:-.05em; }
.footer-copy { color:#74777c; font-size:11px; line-height:1.8; white-space:nowrap; }
@media (max-width:700px) {
    .site-header-inner { min-height:auto; padding:16px 20px; flex-direction:column; align-items:flex-start; gap:14px; }
    .header-menu { width:100%; flex-wrap:wrap; }
    .site-footer-inner { align-items:flex-start; flex-direction:column; gap:14px; }
    .footer-copy { white-space:normal; }
}

/* 로그인 화면 아이디 저장 */
.remember-row {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: -2px 0 16px;
    color: #4b5563;
    font-size: 14px;
    font-weight: 650;
    cursor: pointer;
    user-select: none;
}

.remember-row input {
    width: 16px;
    height: 16px;
    margin: 0;
    accent-color: #102f4f;
}

/* 좌측 메뉴 레이아웃 */
.app-layout {
    width: min(1240px, calc(100% - 40px));
    min-height: calc(100vh - 224px);
    margin: 0 auto;
    display: grid;
    grid-template-columns: 250px minmax(0, 1fr);
    gap: 24px;
    align-items: start;
}

.side-nav {
    position: sticky;
    top: 18px;
    margin: 32px 0 52px;
}

.side-nav-inner {
    overflow: hidden;
    border: 1px solid #e5e7eb;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 14px 36px rgba(15, 23, 42, 0.07);
}

.side-home-link {
    min-height: 54px;
    padding: 0 18px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: 1px solid #eef2f7;
    color: #102f4f;
    text-decoration: none;
    font-size: 15px;
    font-weight: 850;
}

.side-home-link:hover,
.side-home-link.is-active {
    background: #edf7f5;
    color: #166657;
}

.side-home-icon {
    width: 24px;
    height: 24px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: #102f4f;
    color: #ffffff;
    font-size: 14px;
    line-height: 1;
}

.side-menu-group {
    padding: 16px 14px 14px;
    border-bottom: 1px solid #eef2f7;
}

.side-menu-group:last-child {
    border-bottom: 0;
}

.side-menu-title {
    margin: 0 4px 9px;
    color: #111827;
    font-size: 14px;
    font-weight: 850;
    letter-spacing: -0.02em;
}

.side-menu-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.side-menu-list li + li {
    margin-top: 4px;
}

.side-menu-link {
    min-height: 36px;
    padding: 8px 11px;
    display: flex;
    align-items: center;
    border-radius: 10px;
    color: #4b5563;
    text-decoration: none;
    font-size: 14px;
    font-weight: 700;
    transition: background 0.15s ease, color 0.15s ease, transform 0.1s ease;
}

.side-menu-link:hover {
    background: #f3f6fb;
    color: #102f4f;
}

.side-menu-link.is-active {
    background: #102f4f;
    color: #ffffff;
}

.page-container {
    width: 100%;
    max-width: none;
    min-height: auto;
    margin: 0;
    padding: 32px 0 52px;
}

.content-card {
    max-width: none;
}

.content-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 24px;
}

.page-eyebrow {
    margin: 0 0 8px;
    color: #1f7a68;
    font-size: 13px;
    font-weight: 850;
}

.page-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
}

.page-action-link {
    min-height: 40px;
    padding: 9px 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #d1d5db;
    border-radius: 11px;
    background: #ffffff;
    color: #374151;
    text-decoration: none;
    font-size: 14px;
    font-weight: 800;
}

.page-action-link.primary {
    border-color: #102f4f;
    background: #102f4f;
    color: #ffffff;
}

.empty-state {
    min-height: 180px;
    padding: 34px 24px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border: 1px dashed #cbd5e1;
    border-radius: 16px;
    background: #f8fafc;
    color: #64748b;
    text-align: center;
}

.empty-state strong {
    margin-bottom: 8px;
    color: #1f2937;
    font-size: 18px;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    margin-top: 22px;
}

.dashboard-menu-card {
    padding: 20px;
    display: block;
    min-height: 132px;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    background: #ffffff;
    color: #374151;
    text-decoration: none;
    transition: transform 0.12s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

.dashboard-menu-card:hover {
    transform: translateY(-2px);
    border-color: #b7d9d3;
    box-shadow: 0 14px 28px rgba(15, 23, 42, 0.08);
}

.dashboard-menu-card .menu-card-group {
    margin-bottom: 8px;
    color: #1f7a68;
    font-size: 12px;
    font-weight: 850;
}

.dashboard-menu-card .menu-card-title {
    margin-bottom: 8px;
    color: #111827;
    font-size: 17px;
    font-weight: 850;
}

.dashboard-menu-card .menu-card-desc {
    color: #6b7280;
    font-size: 13px;
    line-height: 1.55;
}

@media (max-width: 980px) {
    .app-layout {
        width: calc(100% - 32px);
        display: block;
    }

    .side-nav {
        position: static;
        margin: 20px 0 0;
    }

    .side-nav-inner {
        border-radius: 16px;
    }

    .side-menu-group {
        padding-top: 14px;
    }

    .page-container {
        padding-top: 20px;
    }

    .dashboard-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .app-layout {
        width: calc(100% - 24px);
    }

    .content-head {
        display: block;
    }

    .page-actions {
        justify-content: flex-start;
        margin-top: 16px;
    }

    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

/* 기초정보 관리 화면 */
.basic-grid {
    display: grid;
    grid-template-columns: minmax(320px, 420px) minmax(0, 1fr);
    gap: 22px;
    align-items: start;
}

.basic-form-card,
.basic-list-card {
    padding: 24px;
}

.basic-section-title {
    margin: 0 0 16px;
    color: #111827;
    font-size: 18px;
    font-weight: 850;
    letter-spacing: -0.03em;
}

.compact-form .form-group {
    margin-bottom: 14px;
}

.compact-form .form-control,
.compact-form select.form-control {
    height: 44px;
    border-radius: 10px;
    font-size: 14px;
}

.compact-form textarea.form-control {
    min-height: 84px;
    padding-top: 12px;
    resize: vertical;
}

.form-help {
    margin: 6px 0 0;
    color: #6b7280;
    font-size: 12px;
    line-height: 1.45;
}

.form-row-2 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.form-row-3 {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.search-bar {
    display: flex;
    gap: 8px;
    align-items: center;
    margin-bottom: 16px;
}

.search-bar .form-control {
    height: 42px;
    border-radius: 10px;
}

.btn-small {
    width: auto;
    min-width: 74px;
    height: 42px;
    margin: 0;
    padding: 0 14px;
    border-radius: 10px;
    font-size: 14px;
}

.btn-ghost {
    height: 42px;
    min-width: 72px;
    padding: 0 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #d1d5db;
    border-radius: 10px;
    background: #fff;
    color: #374151;
    text-decoration: none;
    font-size: 14px;
    font-weight: 800;
}

.btn-ghost:hover {
    background: #f9fafb;
}

.basic-table-wrap {
    overflow-x: auto;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
}

.basic-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 760px;
    background: #ffffff;
}

.basic-table th,
.basic-table td {
    padding: 12px 13px;
    border-bottom: 1px solid #eef2f7;
    text-align: left;
    vertical-align: middle;
    font-size: 13px;
}

.basic-table th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #f8fafc;
    color: #374151;
    font-weight: 850;
    white-space: nowrap;
}

.basic-table tr:last-child td {
    border-bottom: 0;
}

.basic-table .text-center {
    text-align: center;
}

.table-link {
    color: #102f4f;
    font-weight: 850;
    text-decoration: none;
}

.table-link:hover {
    text-decoration: underline;
}

.badge {
    min-width: 48px;
    padding: 4px 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 850;
}

.badge-on {
    background: #ecfdf5;
    color: #047857;
}

.badge-off {
    background: #f3f4f6;
    color: #6b7280;
}

.badge-warn {
    background: #fff7ed;
    color: #c2410c;
}

.badge-info {
    background: #eff6ff;
    color: #1d4ed8;
}

.required-mark {
    color: #be123c;
    font-weight: 900;
}

@media (max-width: 1080px) {
    .basic-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .form-row-2,
    .form-row-3 {
        grid-template-columns: 1fr;
    }

    .search-bar {
        align-items: stretch;
        flex-direction: column;
    }

    .btn-small,
    .btn-ghost {
        width: 100%;
    }
}

/* 기초정보 분리 화면 */
.full-list-card {
    margin-top: 8px;
}

.form-page-card {
    max-width: 980px;
}

.single-form {
    max-width: 760px;
}

.search-help {
    margin-top: -8px;
    margin-bottom: 14px;
}

.employee-table {
    min-width: 980px;
}

.form-control[readonly] {
    background: #f9fafb;
    color: #6b7280;
    cursor: not-allowed;
}

/* 2026-04-29 상단 메뉴 레이아웃 전환 */
.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
}

.site-header-inner {
    max-width: none;
    width: min(1520px, calc(100% - 40px));
    min-height: 66px;
    padding: 0;
}

.top-nav {
    border-top: 1px solid #eef2f7;
    background: #102f4f;
}

.top-nav-inner {
    width: min(1520px, calc(100% - 40px));
    min-height: 46px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 8px;
}

.top-home-link,
.top-menu-button {
    height: 36px;
    padding: 0 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: rgba(255, 255, 255, 0.86);
    text-decoration: none;
    font: inherit;
    font-size: 14px;
    font-weight: 850;
    cursor: pointer;
    white-space: nowrap;
}

.top-home-link:hover,
.top-home-link.is-active,
.top-menu-group:hover .top-menu-button,
.top-menu-group.is-active .top-menu-button {
    background: rgba(255, 255, 255, 0.14);
    color: #ffffff;
}

.top-menu-group {
    position: relative;
    /*
     * 버튼과 하위메뉴 사이에 마우스가 지나갈 수 있는 영역을 만든다.
     * 기존에는 panel top에 5px 간격이 있어 버튼에서 하위메뉴로 이동하는 순간
     * hover가 끊기면서 메뉴가 닫히는 경우가 있었다.
     */
    padding: 5px 0;
    margin: -5px 0;
}

.top-menu-panel {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 210px;
    padding: 8px;
    display: none;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 18px 38px rgba(15, 23, 42, 0.16);
    z-index: 1000;
}

/* 버튼에서 하위메뉴로 내려갈 때 hover가 끊기지 않도록 투명 브릿지 영역 유지 */
.top-menu-panel::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: -10px;
    height: 10px;
}

.top-menu-group:hover .top-menu-panel,
.top-menu-group:focus-within .top-menu-panel {
    display: block;
}

.top-menu-link {
    min-height: 38px;
    padding: 9px 11px;
    display: flex;
    align-items: center;
    border-radius: 10px;
    color: #374151;
    text-decoration: none;
    font-size: 14px;
    font-weight: 750;
    white-space: nowrap;
}

.top-menu-link:hover,
.top-menu-link.is-active {
    background: #edf7f5;
    color: #166657;
}

.page-container {
    width: min(1520px, calc(100% - 40px));
    max-width: none;
    min-height: calc(100vh - 220px);
    margin: 0 auto;
    padding: 24px 0 48px;
}

.content-card {
    padding: 24px;
}

.basic-list-card {
    padding: 20px;
}

.basic-table-wrap {
    overflow-x: visible;
}

.basic-table {
    min-width: 0;
    table-layout: auto;
}

.basic-table th,
.basic-table td {
    padding: 11px 12px;
    word-break: keep-all;
}

.employee-table th,
.employee-table td {
    font-size: 13px;
}

.employee-table th:nth-child(1),
.employee-table td:nth-child(1) { width: 13%; }
.employee-table th:nth-child(2),
.employee-table td:nth-child(2) { width: 18%; }
.employee-table th:nth-child(3),
.employee-table td:nth-child(3) { width: 20%; }
.employee-table th:nth-child(4),
.employee-table td:nth-child(4) { width: 15%; }
.employee-table th:nth-child(5),
.employee-table td:nth-child(5) { width: 10%; }
.employee-table th:nth-child(6),
.employee-table td:nth-child(6) { width: 8%; }
.employee-table th:nth-child(7),
.employee-table td:nth-child(7) { width: 8%; }

.search-bar-wide .search-select {
    flex: 0 0 150px;
}

.search-bar-wide input.form-control {
    flex: 1 1 auto;
    min-width: 220px;
}

@media (max-width: 900px) {
    .site-header {
        position: static;
    }

    .site-header-inner,
    .top-nav-inner,
    .page-container {
        width: calc(100% - 24px);
    }

    .site-header-inner {
        min-height: auto;
        padding: 14px 0;
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .top-nav-inner {
        padding: 8px 0;
        align-items: flex-start;
        flex-wrap: wrap;
    }

    .top-menu-group {
        padding: 0;
        margin: 0;
        width: 100%;
    }

    .top-menu-panel {
        position: static;
        min-width: 100%;
        margin-top: 4px;
        box-shadow: none;
    }

    .top-menu-panel::before {
        display: none;
    }

    .top-menu-group:hover .top-menu-panel,
    .top-menu-group:focus-within .top-menu-panel {
        display: block;
    }

    .content-head {
        display: block;
    }

    .page-actions {
        justify-content: flex-start;
        margin-top: 14px;
    }
}

@media (max-width: 720px) {
    .basic-table-wrap {
        border: 0;
    }

    .basic-table,
    .basic-table thead,
    .basic-table tbody,
    .basic-table tr,
    .basic-table th,
    .basic-table td {
        display: block;
        width: 100% !important;
    }

    .basic-table thead {
        display: none;
    }

    .basic-table tr {
        margin-bottom: 10px;
        border: 1px solid #e5e7eb;
        border-radius: 14px;
        background: #ffffff;
        overflow: hidden;
    }

    .basic-table td {
        border-bottom: 1px solid #eef2f7;
    }

    .basic-table td:last-child {
        border-bottom: 0;
    }
}

/* 작업로그/엑셀 다운로드 화면 보정 */
.log-search-bar {
    flex-wrap: wrap;
}

.log-search-bar .compact-date {
    flex: 0 0 150px;
}

.log-search-bar .log-action-select {
    flex: 0 0 160px;
}

.log-search-bar input[type="text"].form-control {
    flex: 1 1 280px;
    min-width: 240px;
}

.log-table-wrap {
    overflow-x: auto;
}

.log-table {
    min-width: 1180px;
}

.log-table th,
.log-table td {
    font-size: 12px;
}

.log-detail-cell {
    max-width: 260px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}


/* 엑셀 저장 버튼 */
.page-action-link.excel-action-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-height: 42px;
    padding: 0 16px;
    border: 1px solid #1f6f43;
    border-radius: 12px;
    background: linear-gradient(180deg, #2f8f57 0%, #217346 100%);
    color: #ffffff;
    text-decoration: none;
    font-size: 14px;
    font-weight: 800;
    box-shadow: 0 10px 18px rgba(33, 115, 70, 0.18);
    transition: background .15s ease, border-color .15s ease, transform .08s ease, box-shadow .15s ease;
}
.page-action-link.excel-action-link:hover {
    border-color: #165735;
    background: linear-gradient(180deg, #27804d 0%, #185f39 100%);
    color: #ffffff;
    box-shadow: 0 12px 22px rgba(24, 95, 57, 0.24);
}
.page-action-link.excel-action-link:active {
    transform: translateY(1px);
}
.excel-icon {
    position: relative;
    width: 22px;
    height: 24px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    background: #ffffff;
    color: #217346;
    font-size: 11px;
    font-weight: 900;
    line-height: 1;
    box-shadow: inset 0 0 0 1px rgba(33, 115, 70, 0.18);
    flex: 0 0 22px;
}
.excel-icon::before {
    content: 'X';
    position: relative;
    z-index: 1;
}
.excel-icon::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 0;
    height: 0;
    border-top: 8px solid rgba(33, 115, 70, 0.18);
    border-left: 8px solid transparent;
    border-top-right-radius: 2px;
}


/* 목록 페이지네이션 */
.list-summary {
    margin: 12px 0 14px;
    color: #6b7280;
    font-size: 13px;
    line-height: 1.5;
}
.pagination {
    margin-top: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex-wrap: wrap;
}
.pagination-link,
.pagination-current,
.pagination-disabled {
    min-width: 36px;
    height: 36px;
    padding: 0 11px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 800;
    text-decoration: none;
}
.pagination-link {
    border: 1px solid #d1d5db;
    background: #ffffff;
    color: #374151;
}
.pagination-link:hover {
    background: #f3f6fb;
    border-color: #9ca3af;
}
.pagination-current {
    border: 1px solid #102f4f;
    background: #102f4f;
    color: #ffffff;
}
.pagination-disabled {
    border: 1px solid #e5e7eb;
    background: #f9fafb;
    color: #a3a8b2;
}

/* 환경설정 화면 */
.setting-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 22px;
}
.setting-grid.setting-grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}
.setting-grid .form-group {
    margin-bottom: 0;
}
.setting-section {
    margin-top: 22px;
    padding-top: 22px;
    border-top: 1px solid #e5e7eb;
}
.setting-section:first-of-type {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
}
.setting-section-title {
    margin: 0 0 16px;
    font-size: 17px;
    font-weight: 850;
    color: #111827;
    letter-spacing: -0.03em;
}
.setting-sub-text {
    margin: -6px 0 16px;
    color: #6b7280;
    font-size: 13px;
    line-height: 1.6;
}
.setting-form-card {
    max-width: 1080px;
}
.setting-list-card {
    max-width: none;
}
.form-control.compact-number,
.form-control.compact-time,
.form-control.compact-select {
    max-width: 220px;
}
.table-nowrap {
    white-space: nowrap;
}
.policy-table td,
.policy-table th,
.setting-table td,
.setting-table th {
    font-size: 13px;
}
@media (max-width: 900px) {
    .setting-grid,
    .setting-grid.setting-grid-3 {
        grid-template-columns: 1fr;
    }
    .form-control.compact-number,
    .form-control.compact-time,
    .form-control.compact-select {
        max-width: none;
    }
}

/* 근무설정 화면 폭 확장 및 최신 설정 항목 정리 */
/* 본문 폭은 상단 로고/메뉴 영역과 같은 기준으로 맞춥니다. */
.page-container {
    width: min(1520px, calc(100% - 40px));
    max-width: none;
    margin-left: auto;
    margin-right: auto;
}
.setting-form-card,
.setting-list-card {
    width: 100%;
    max-width: none;
}
.content-form.wide-form {
    width: 100%;
    max-width: none;
}
.setting-grid.setting-grid-4,
.setting-grid.setting-grid-3,
.setting-grid {
    grid-template-columns: repeat(4, minmax(180px, 1fr));
}
.setting-grid .form-control {
    max-width: none;
}
.form-control.compact-number,
.form-control.compact-time,
.form-control.compact-select,
.form-control.compact-date {
    max-width: none;
}
@media (max-width: 1100px) {
    .setting-grid.setting-grid-4,
    .setting-grid.setting-grid-3,
    .setting-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
@media (max-width: 700px) {
    .page-container {
        width: calc(100% - 24px);
    }
    .setting-grid.setting-grid-4,
    .setting-grid.setting-grid-3,
    .setting-grid {
        grid-template-columns: 1fr;
    }
}


/* 근무설정 폼 행 정렬 보조 */
.setting-grid-break {
    grid-column: 1 / -1;
    height: 0;
    min-height: 0;
}
.fixed-value-box {
    min-height: 42px;
    display: flex;
    align-items: center;
    padding: 0 14px;
    border: 1px solid #d1d5db;
    border-radius: 12px;
    background: #f8fafc;
    color: #102f4f;
    font-weight: 800;
}

#dept_policy_group.is-disabled {
    opacity: .58;
}
#dept_policy_group.is-disabled select {
    background: #f3f4f6;
    cursor: not-allowed;
}

/* 보조 설명 텍스트 */
.muted-text {
    color: #64748b;
    font-size: 12px;
}


/* 근태업무 화면 */
.attendance-page-card {
    padding: 24px;
}
.attendance-wide-card {
    max-width: none;
}
.compact-content-head {
    margin-bottom: 18px;
}
.legacy-filter-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 14px;
    padding: 14px 16px;
    margin-bottom: 14px;
    border: 1px solid #d8dde7;
    background: #f3f5f8;
    color: #172033;
    font-size: 14px;
}
.legacy-filter-bar label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 0;
    font-weight: 700;
    white-space: nowrap;
}
.attendance-filter-bar .form-control,
.legacy-register-form .form-control {
    min-height: 34px;
    height: 34px;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 14px;
}
.compact-date { width: 145px; }
.compact-year { width: 98px; }
.compact-month { width: 78px; }
.compact-select { min-width: 110px; }
.compact-keyword { width: 160px; }
.compact-time-small { width: 96px; }
.btn-excel-mini,
.btn-teal-mini,
.btn-blue-mini {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 74px;
    height: 42px;
    min-height: 42px;
    padding: 0 14px;
    border: 0;
    border-radius: 10px;
    color: #fff;
    font-size: 14px;
    font-weight: 800;
    line-height: 1;
    text-decoration: none;
    cursor: pointer;
    box-shadow: none;
    transition: background 0.15s ease, transform 0.1s ease, filter 0.15s ease;
}
.btn-excel-mini { background: #217346; }
.btn-teal-mini { background: #148b88; }
.btn-blue-mini { background: #0a84c1; margin-left: 8px; }
.btn-excel-mini:hover,
.btn-teal-mini:hover,
.btn-blue-mini:hover {
    filter: brightness(0.94);
}
.btn-excel-mini:active,
.btn-teal-mini:active,
.btn-blue-mini:active {
    transform: translateY(1px);
}
.legacy-toolbar-note {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    min-height: 44px;
    padding: 8px 14px;
    margin-bottom: 8px;
    border: 1px solid #e3d9b7;
    background: #fff8df;
    color: #4d3b10;
    font-size: 13px;
}
.legacy-table-wrap {
    width: 100%;
    overflow-x: auto;
}
.legacy-table {
    width: 100%;
    border-collapse: collapse;
    border-top: 2px solid #4f5a82;
    background: #fff;
    font-size: 13px;
}
.legacy-table th,
.legacy-table td {
    border: 1px solid #d0d4dc;
    padding: 7px 8px;
    vertical-align: middle;
}
.legacy-table th {
    background: #515b82;
    color: #fff;
    text-align: center;
    font-weight: 800;
}
.legacy-table tbody tr:nth-child(even) td {
    background: #fbfcfe;
}
.legacy-table tbody tr:hover td,
.basic-table tbody tr:hover td {
    background: #eef6ff !important;
}
.basic-table tbody tr:nth-child(even) td {
    background: #fbfcfe;
}
.legacy-table .text-center {
    text-align: center;
}
.legacy-help {
    margin: 10px 0 0;
    color: #5f6b7a;
    font-size: 13px;
}
.monthly-scroll-wrap {
    max-height: 66vh;
    overflow: auto;
}
.monthly-attendance-table {
    width: max-content;
    min-width: 100%;
}
.monthly-attendance-table th,
.monthly-attendance-table td {
    min-width: 48px;
    padding: 6px 7px;
    white-space: nowrap;
}
.monthly-attendance-table .sticky-col {
    position: sticky;
    left: 0;
    z-index: 2;
    min-width: 110px;
}
.monthly-attendance-table th.sticky-col {
    z-index: 4;
}
.monthly-attendance-table td.sticky-col {
    background: #fff;
}
.employee-name-cell {
    font-weight: 700;
    color: #172033;
}
.day-head,
.weekday-head {
    min-width: 44px !important;
}
.sunday-head {
    background: #ef6b6b !important;
}
.muted-time {
    color: #9aa3b2;
}
.legacy-register-box {
    margin: 14px 0;
    border: 3px solid #24347a;
    background: #f4f0ea;
}
.legacy-register-title {
    padding: 8px 10px;
    background: #6381c9;
    color: #fff;
    text-align: center;
    font-weight: 900;
}
.legacy-register-form {
    padding: 12px;
}
.legacy-register-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 14px;
    padding: 8px 0;
    border-bottom: 1px solid #d9d1c5;
}
.legacy-register-row:last-child {
    border-bottom: 0;
}
.legacy-register-row label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
}
.legacy-register-row .wide-label {
    flex: 1 1 520px;
}
.legacy-register-row .wide-label input {
    width: 100%;
}
.overtime-order-table th,
.overtime-order-table td,
.check-log-table th,
.check-log-table td,
.personal-attendance-table th,
.personal-attendance-table td {
    white-space: nowrap;
}

@media (max-width: 900px) {
    .attendance-page-card { padding: 16px; }
    .legacy-filter-bar { align-items: stretch; }
    .legacy-filter-bar label { width: 100%; justify-content: space-between; }
    .compact-keyword,
    .compact-date,
    .compact-select,
    .compact-year,
    .compact-month { width: 100%; }
}


/* 초과근무명령서 등록 폼: 대상자 자동완성/할일 입력폭 보정 */
.target-employee-label {
    position: relative;
}
.employee-suggest-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
}
.target-employee-input {
    width: 210px;
}
.employee-suggest-box {
    position: absolute;
    left: 0;
    top: calc(100% + 4px);
    z-index: 30;
    width: 360px;
    max-height: 260px;
    overflow-y: auto;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 12px 26px rgba(15, 23, 42, .18);
}
.employee-suggest-item {
    display: block;
    width: 100%;
    padding: 9px 11px;
    border: 0;
    border-bottom: 1px solid #e5e7eb;
    background: #fff;
    color: #172033;
    text-align: left;
    cursor: pointer;
}
.employee-suggest-item:hover {
    background: #eef6ff;
}
.employee-suggest-item strong {
    display: block;
    font-size: 13px;
}
.employee-suggest-item span,
.employee-suggest-empty {
    display: block;
    color: #64748b;
    font-size: 12px;
    line-height: 1.45;
}
.employee-suggest-empty {
    padding: 10px 11px;
}
.overtime-reason-row {
    flex-wrap: nowrap;
}
.overtime-reason-label {
    flex: 0 0 auto;
    white-space: nowrap;
}
.overtime-reason-input {
    width: 520px !important;
    max-width: 52vw;
}
.overtime-register-help {
    margin: 4px 12px 12px;
}
@media (max-width: 900px) {
    .target-employee-input,
    .employee-suggest-box,
    .overtime-reason-input {
        width: 100% !important;
        max-width: none;
    }
    .employee-suggest-wrap {
        width: 100%;
    }
    .overtime-reason-row {
        flex-wrap: wrap;
    }
}

/* 직원별 유연근무 설정 */
.table-actions-inline {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    white-space: nowrap;
}
.employee-flex-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}
.employee-flex-summary > div {
    min-height: 58px;
    padding: 14px 16px;
    border: 1px solid #dbe3ef;
    border-radius: 14px;
    background: #f8fafc;
}
.employee-flex-summary strong {
    display: block;
    margin-bottom: 6px;
    color: #607086;
    font-size: 12px;
}
.employee-flex-summary span {
    color: #10233f;
    font-weight: 800;
}
.employee-flex-form {
    margin-top: 18px;
}
.flex-day-title {
    margin-top: 26px;
}
.employee-flex-table th,
.employee-flex-table td {
    vertical-align: middle;
}
.employee-flex-table input[type="time"],
.employee-flex-table input[type="number"],
.employee-flex-table select {
    min-height: 38px;
}
@media (max-width: 980px) {
    .employee-flex-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
@media (max-width: 640px) {
    .employee-flex-summary {
        grid-template-columns: 1fr;
    }
}


/* 요일 색상 구분: 일요일/토요일 */
.sunday-head,
.sunday-cell,
.flex-sunday-row > td {
    background: #fff1f2 !important;
    color: #b42318 !important;
}
.saturday-head,
.saturday-cell,
.flex-saturday-row > td {
    background: #eff6ff !important;
    color: #175cd3 !important;
}
.employee-flex-table .flex-sunday-row td:first-child strong {
    color: #b42318;
}
.employee-flex-table .flex-saturday-row td:first-child strong {
    color: #175cd3;
}
.monthly-attendance-table td.sunday-cell,
.monthly-attendance-table td.saturday-cell {
    font-weight: 700;
}

/* 초과근무명령서 등록 폼 보정 */
.overtime-register-box {
    display: none;
}
.overtime-register-box.is-open {
    display: block;
}
.overtime-time-label {
    white-space: nowrap;
}
.overtime-time-input {
    width: 122px !important;
    min-width: 122px;
}
.overtime-reason-input {
    width: 420px !important;
    max-width: 42vw;
}
.legacy-filter-bar button.btn-teal-mini {
    border: 0;
    cursor: pointer;
}
@media (max-width: 900px) {
    .overtime-time-input {
        width: 100% !important;
        min-width: 0;
    }
    .overtime-time-label {
        white-space: normal;
    }
}

/* 공통 레이어 알림 */
.alert.flycheck-alert-source,
.alert[data-flycheck-modalized="1"] {
    display: none !important;
}

.flycheck-alert-layer {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.flycheck-alert-layer.is-visible {
    display: flex;
}

.flycheck-alert-dim {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.42);
    backdrop-filter: blur(2px);
}

.flycheck-alert-box {
    position: relative;
    width: min(460px, calc(100vw - 36px));
    overflow: hidden;
    border-radius: 18px;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.24);
    outline: none;
    animation: flycheckAlertPop 0.16s ease-out;
}

.flycheck-alert-head {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px 22px 12px;
}

.flycheck-alert-icon {
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 20px;
    font-weight: 900;
    line-height: 1;
}

.flycheck-alert-title-wrap {
    min-width: 0;
    flex: 1;
}

.flycheck-alert-title {
    margin: 0;
    color: #111827;
    font-size: 18px;
    font-weight: 850;
    letter-spacing: -0.03em;
}

.flycheck-alert-x {
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: #6b7280;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
}

.flycheck-alert-x:hover {
    background: #f3f4f6;
    color: #111827;
}

.flycheck-alert-message {
    padding: 4px 22px 22px 70px;
    color: #374151;
    font-size: 15px;
    line-height: 1.6;
    word-break: keep-all;
    white-space: pre-line;
}

.flycheck-alert-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    padding: 16px 22px 20px;
    background: #f9fafb;
    border-top: 1px solid #eef2f7;
}

.flycheck-alert-cancel,
.flycheck-alert-ok {
    min-width: 92px;
    height: 42px;
    padding: 0 20px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 850;
    cursor: pointer;
}

.flycheck-alert-cancel {
    border: 1px solid #d1d5db;
    background: #ffffff;
    color: #374151;
}

.flycheck-alert-cancel:hover {
    background: #f3f4f6;
    color: #111827;
}

.flycheck-alert-ok {
    border: 0;
    background: #102f4f;
    color: #ffffff;
    box-shadow: 0 8px 18px rgba(16, 47, 79, 0.18);
}

.flycheck-alert-ok:hover {
    background: #0b253f;
}

.flycheck-alert-ok:active {
    transform: translateY(1px);
}

.flycheck-alert-layer.is-error .flycheck-alert-icon {
    background: #fff1f2;
    color: #be123c;
}

.flycheck-alert-layer.is-warning .flycheck-alert-icon {
    background: #fffbeb;
    color: #b45309;
}

.flycheck-alert-layer.is-success .flycheck-alert-icon {
    background: #ecfdf5;
    color: #047857;
}

.flycheck-alert-layer.is-info .flycheck-alert-icon {
    background: #eff6ff;
    color: #1d4ed8;
}

@keyframes flycheckAlertPop {
    from {
        opacity: 0;
        transform: translateY(8px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@media (max-width: 520px) {
    .flycheck-alert-layer {
        padding: 18px;
    }

    .flycheck-alert-head {
        padding: 18px 18px 10px;
    }

    .flycheck-alert-message {
        padding: 4px 18px 20px 66px;
    }

    .flycheck-alert-actions {
        padding: 14px 18px 18px;
    }
}

/* 특별공제작성 / 사후승인 공통 등록 폼 */
.attendance-register-box {
    display: none;
}
.attendance-register-box.is-open {
    display: block;
}
.deduction-rule-select {
    min-width: 330px;
}
.deduction-write-table th,
.deduction-write-table td,
.after-approval-table th,
.after-approval-table td {
    white-space: nowrap;
}
.after-time-label {
    white-space: nowrap;
}
.after-reason-row,
.deduction-memo-row {
    flex-wrap: nowrap;
}
@media (max-width: 900px) {
    .deduction-rule-select {
        min-width: 0;
        width: 100%;
    }
    .after-reason-row,
    .deduction-memo-row {
        flex-wrap: wrap;
    }
}

/* 특별공제작성: 한 달 달력형 일괄 등록 */
.deduction-calendar-panel {
    margin: 10px 0 8px;
    padding: 12px;
    border: 1px solid #cfd8e3;
    border-radius: 12px;
    background: #ffffff;
}
.deduction-calendar-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
    color: #172033;
}
.deduction-calendar-head strong {
    font-size: 15px;
    font-weight: 900;
}
.deduction-calendar-tools {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.deduction-calendar-control {
    height: 32px;
    min-width: auto;
    padding: 0 10px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 800;
}
.deduction-calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(58px, 1fr));
    gap: 6px;
}
.deduction-calendar-week-head {
    margin-bottom: 6px;
}
.deduction-calendar-week-head > div {
    padding: 7px 4px;
    border-radius: 8px;
    background: #eef2f7;
    color: #374151;
    text-align: center;
    font-size: 13px;
    font-weight: 900;
}
.deduction-calendar-week-head > div.is-sunday {
    background: #fff1f2;
    color: #be123c;
}
.deduction-calendar-week-head > div.is-saturday {
    background: #eff6ff;
    color: #1d4ed8;
}

.deduction-calendar-week-head > .deduction-week-head-label {
    min-height: 34px;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 5px !important;
    padding: 7px 4px;
    border-radius: 8px;
    background: #eef2f7;
    color: #374151;
    text-align: center;
    font-size: 13px;
    font-weight: 900 !important;
    white-space: nowrap;
    cursor: pointer;
}
.deduction-calendar-week-head > .deduction-week-head-label input {
    width: 14px;
    height: 14px;
    margin: 0;
}
.deduction-calendar-week-head > .deduction-week-head-label.is-sunday {
    background: #fff1f2;
    color: #be123c;
}
.deduction-calendar-week-head > .deduction-week-head-label.is-saturday {
    background: #eff6ff;
    color: #1d4ed8;
}
.deduction-calendar-day {
    min-height: 44px;
    display: flex !important;
    align-items: center;
    justify-content: center;
    gap: 6px !important;
    padding: 8px 6px;
    border: 1px solid #d8dde7;
    border-radius: 10px;
    background: #fff;
    color: #172033;
    font-weight: 850 !important;
    cursor: pointer;
    user-select: none;
}
.deduction-calendar-day input {
    width: 16px;
    height: 16px;
    margin: 0;
}
.deduction-calendar-day.is-sunday {
    border-color: #fecdd3;
    background: #fff7f8;
    color: #be123c;
}
.deduction-calendar-day.is-saturday {
    border-color: #bfdbfe;
    background: #f8fbff;
    color: #1d4ed8;
}
.deduction-calendar-day.is-other-month {
    border-style: dashed;
    background: #f8fafc;
    color: #cbd5e1;
    cursor: default;
}
.deduction-calendar-day:has(input:checked) {
    border-color: #148b88;
    background: #ecfdf5;
    color: #065f46;
    box-shadow: inset 0 0 0 1px rgba(20, 139, 136, .24);
}

/* 사후승인: 사유 입력 영역 폭 보정 */
.after-reason-row {
    flex-wrap: nowrap;
}
.after-reason-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex: 0 0 auto;
    white-space: nowrap;
    font-weight: 700;
}
.after-reason-input {
    width: 420px !important;
    max-width: 42vw;
}

@media (max-width: 900px) {
    .deduction-calendar-head {
        align-items: flex-start;
        flex-direction: column;
    }
    .deduction-calendar-tools {
        flex-wrap: wrap;
    }
    .deduction-calendar-grid {
        grid-template-columns: repeat(7, minmax(38px, 1fr));
        gap: 4px;
    }
    .deduction-calendar-day {
        min-height: 38px;
        gap: 3px !important;
        padding: 6px 3px;
        font-size: 12px;
    }
    .after-reason-row {
        flex-wrap: wrap;
    }
    .after-reason-label,
    .after-reason-input {
        width: 100% !important;
        max-width: none;
    }
}

/* 사후승인 / 특별공제작성 보정: 한 줄 등록 폼, 짧은 입력폭, 줄바꿈 방지 */
.after-register-form,
.deduction-register-form {
    overflow-x: auto;
}
.after-register-line,
.deduction-register-line,
.deduction-memo-row {
    flex-wrap: nowrap !important;
    align-items: center;
    gap: 10px 12px;
}
.after-register-line label,
.deduction-register-line label,
.deduction-memo-row label,
.after-time-label,
.after-reason-label,
.deduction-rule-label,
.deduction-memo-label {
    white-space: nowrap !important;
    flex: 0 0 auto;
}
.after-register-line .target-employee-input,
.deduction-register-line .target-employee-input {
    width: 170px;
}
.after-register-line .compact-date {
    width: 142px;
}
.after-register-line .compact-select {
    width: 88px;
    min-width: 88px;
}
.after-register-line .compact-time-small {
    width: 102px;
}
.after-register-line .after-reason-input {
    width: 300px !important;
    max-width: none;
}
.deduction-rule-select {
    width: 330px;
    min-width: 330px;
}
.deduction-memo-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
}
.deduction-memo-input {
    width: 300px !important;
    max-width: none;
}
.deduction-write-table td:nth-child(8),
.after-approval-table td:nth-child(8) {
    max-width: 320px;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 특별공제작성: 요일 헤더 체크 선택 및 기존 등록일 표시 */
.deduction-weekday-picker {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    margin: 0 0 10px;
    padding: 8px 10px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    background: #f8fafc;
}
.deduction-weekday-title {
    margin-right: 4px;
    color: #334155;
    font-size: 13px;
    font-weight: 900;
    white-space: nowrap;
}
.deduction-weekday-label {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 4px !important;
    min-width: 46px;
    min-height: 30px;
    padding: 4px 8px;
    border: 1px solid #cbd5e1;
    border-radius: 999px;
    background: #fff;
    color: #172033;
    font-size: 13px;
    font-weight: 850 !important;
    cursor: pointer;
    white-space: nowrap;
}
.deduction-weekday-label input {
    width: 14px;
    height: 14px;
    margin: 0;
}
.deduction-weekday-label.is-sunday {
    border-color: #fecdd3;
    background: #fff7f8;
    color: #be123c;
}
.deduction-weekday-label.is-saturday {
    border-color: #bfdbfe;
    background: #f8fbff;
    color: #1d4ed8;
}
.deduction-calendar-day.is-existing {
    position: relative;
    border-color: #7c3aed !important;
    background: #f5f3ff !important;
    color: #5b21b6 !important;
    box-shadow: inset 0 0 0 1px rgba(124, 58, 237, .22);
}
.deduction-calendar-day.is-existing::after {
    content: '등록';
    position: absolute;
    right: 5px;
    bottom: 3px;
    color: #6d28d9;
    font-size: 10px;
    font-weight: 900;
    line-height: 1;
}
.deduction-calendar-note {
    margin: 8px 2px 0;
    color: #64748b;
    font-size: 12px;
    font-weight: 700;
}

@media (max-width: 1100px) {
    .after-register-line,
    .deduction-register-line,
    .deduction-memo-row {
        flex-wrap: wrap !important;
    }
    .after-register-line .after-reason-input,
    .deduction-memo-input,
    .deduction-rule-select {
        width: 100% !important;
        min-width: 0;
    }
}

/* 공통 리스트 테이블 스타일 통일
   - 기초정보/환경설정(basic-table)과 근태업무(legacy-table)의 목록 스타일을 동일하게 맞춥니다.
   - 기존 홀짝 줄 배경과 hover 강조는 유지합니다. */
.basic-table-wrap,
.legacy-table-wrap {
    width: 100%;
    overflow-x: auto;
    border: 0;
    border-radius: 0;
}
.basic-table,
.legacy-table {
    width: 100%;
    min-width: 0;
    table-layout: auto;
    border-collapse: collapse;
    border-top: 2px solid #4f5a82;
    background: #fff;
    font-size: 13px;
}
.basic-table th,
.basic-table td,
.legacy-table th,
.legacy-table td {
    border: 1px solid #d0d4dc;
    padding: 7px 8px;
    vertical-align: middle;
    word-break: keep-all;
}
.basic-table th,
.legacy-table th {
    position: static;
    top: auto;
    z-index: auto;
    background: #515b82;
    color: #fff;
    text-align: center;
    font-weight: 800;
    white-space: nowrap;
}
.basic-table tbody tr:nth-child(even) td,
.legacy-table tbody tr:nth-child(even) td {
    background: #fbfcfe;
}
.basic-table tbody tr:hover td,
.legacy-table tbody tr:hover td {
    background: #eaf3ff !important;
}
.basic-table .text-center,
.legacy-table .text-center {
    text-align: center;
}
.basic-table tr:last-child td,
.legacy-table tr:last-child td {
    border-bottom: 1px solid #d0d4dc;
}


/* 공통 목록: 정렬 가능한 테이블 헤더 */
.legacy-table th.sortable-th,
.basic-table th.sortable-th {
    padding: 0;
}
.legacy-table th.sortable-th a,
.basic-table th.sortable-th a {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    width: 100%;
    min-height: 42px;
    padding: 10px 8px;
    color: inherit;
    text-decoration: none;
    white-space: nowrap;
    box-sizing: border-box;
}
.legacy-table th.sortable-th a:hover,
.basic-table th.sortable-th a:hover {
    background: rgba(255, 255, 255, .12);
}
.sort-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 12px;
    font-size: 10px;
    font-weight: 900;
    line-height: 1;
}
.sort-icon.is-muted {
    opacity: .45;
}

/* 공통 리스트 테이블 스타일: basic-table 기준으로 통일
   - 기초정보/환경설정/근태업무 목록을 밝고 깔끔한 테이블 스타일로 맞춥니다.
   - 기존 줄무늬와 hover 강조, 정렬 헤더 기능은 유지합니다. */
.basic-table-wrap,
.legacy-table-wrap {
    width: 100%;
    overflow-x: auto;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    background: #ffffff;
}
.basic-table,
.legacy-table {
    width: 100%;
    min-width: 0;
    table-layout: auto;
    border-collapse: separate;
    border-spacing: 0;
    border-top: 0;
    background: #ffffff;
    font-size: 13px;
}
.basic-table th,
.basic-table td,
.legacy-table th,
.legacy-table td {
    padding: 11px 12px;
    border: 0;
    border-bottom: 1px solid #eef2f7;
    vertical-align: middle;
    word-break: keep-all;
}
.basic-table th,
.legacy-table th {
    position: static;
    top: auto;
    z-index: auto;
    background: #f8fafc;
    color: #374151;
    text-align: center;
    font-weight: 850;
    white-space: nowrap;
}
.basic-table tbody tr:nth-child(even) td,
.legacy-table tbody tr:nth-child(even) td {
    background: #fbfcfe;
}
.basic-table tbody tr:hover td,
.legacy-table tbody tr:hover td {
    background: #eaf3ff !important;
}
.basic-table .text-center,
.legacy-table .text-center {
    text-align: center;
}
.basic-table tr:last-child td,
.legacy-table tr:last-child td {
    border-bottom: 0;
}
.legacy-table th.sortable-th,
.basic-table th.sortable-th {
    padding: 0;
}
.legacy-table th.sortable-th a,
.basic-table th.sortable-th a {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    width: 100%;
    min-height: 42px;
    padding: 10px 8px;
    color: inherit;
    text-decoration: none;
    white-space: nowrap;
    box-sizing: border-box;
}
.legacy-table th.sortable-th a:hover,
.basic-table th.sortable-th a:hover {
    background: #eef4ff;
}
.sort-icon {
    color: #64748b;
}
.sort-icon.is-muted {
    opacity: .55;
}

/* 직원정보 관리 컬럼 정리
   - basic-table 통일 이후 관리 컬럼 폭이 좁아져 '수정 / 유연근무'가 겹치거나 줄바꿈되는 현상을 방지합니다. */
.employee-table th:nth-child(7),
.employee-table td:nth-child(7) {
    width: 13%;
    min-width: 126px;
}
.employee-table td.table-actions-inline {
    white-space: nowrap;
    text-align: center;
}
.employee-table td.table-actions-inline .table-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0 5px;
    line-height: 1.2;
    white-space: nowrap;
    vertical-align: middle;
}
.employee-table td.table-actions-inline .table-link + .table-link {
    margin-left: 8px;
}
@media (max-width: 900px) {
    .employee-table th:nth-child(7),
    .employee-table td:nth-child(7) {
        min-width: 126px;
    }
}

/* 직원정보/근태업무 리스트 가운데 정렬
   - 직원정보(employee-table)와 근태업무(attendance-table) 목록 본문을 가운데 정렬합니다.
   - 기본/환경설정 목록은 기존 정렬을 유지합니다. */
.employee-table th,
.employee-table td,
.attendance-table th,
.attendance-table td {
    text-align: center;
}

/* 정렬 가능한 헤더는 내부 링크가 flex이므로 기존 중앙 정렬을 유지합니다. */
.employee-table th.sortable-th a,
.attendance-table th.sortable-th a {
    justify-content: center;
}

/* 직원정보 관리 컬럼 표시 보정
   - .table-actions-inline 공통 flex 스타일이 <td>에 직접 적용되면 테이블 셀 폭/배경이 깨질 수 있어
     테이블 안에서는 원래 table-cell 흐름을 유지합니다. */
.basic-table td.table-actions-inline,
.legacy-table td.table-actions-inline,
.employee-table td.table-actions-inline {
    display: table-cell !important;
    white-space: nowrap;
    text-align: center;
    vertical-align: middle;
    min-width: 150px;
}
.employee-table td.table-actions-inline .table-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0 7px;
    line-height: 1.2;
    white-space: nowrap;
    vertical-align: middle;
}
.employee-table td.table-actions-inline .table-link + .table-link {
    margin-left: 10px;
}

/* 근태데이터 만들기 확인 박스 */
.attendance-result-note {
    margin: 12px 0 14px;
    padding: 10px 14px;
    border: 1px solid #dbeafe;
    background: #f8fbff;
    color: #1e3a8a;
    border-radius: 10px;
    font-size: 13px;
}
.attendance-result-note.is-warning {
    border-color: #fde68a;
    background: #fffbeb;
    color: #92400e;
}
.attendance-rebuild-box {
    margin: 12px 0 18px;
    border: 2px solid #2b3f8f;
    background: #f7f3ec;
}
.attendance-rebuild-title {
    padding: 10px 16px;
    background: #637fc7;
    color: #fff;
    text-align: center;
    font-weight: 900;
}
.attendance-rebuild-body {
    padding: 18px 56px;
    color: #0f2f76;
    line-height: 1.6;
}
.attendance-rebuild-body p {
    margin: 0 0 12px;
}
.attendance-rebuild-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 28px;
    padding: 14px 16px 18px;
    border-top: 1px solid #ddd6cc;
}
.text-danger {
    color: #e11d48;
}
@media (max-width: 900px) {
    .attendance-rebuild-body {
        padding: 16px 20px;
    }
    .attendance-rebuild-actions {
        gap: 12px;
    }
}
.btn-secondary-mini {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 74px;
    height: 42px;
    min-height: 42px;
    padding: 0 14px;
    border: 0;
    border-radius: 10px;
    background: #6b7280;
    color: #fff;
    font-size: 14px;
    font-weight: 800;
    line-height: 1;
    text-decoration: none;
    cursor: pointer;
}
.btn-secondary-mini:hover {
    filter: brightness(0.94);
}

/* 개인 근태 상세 화면
   - 기존 업무 화면과 같은 밝은 basic-table 스타일을 유지하면서 월별 상세표를 보기 쉽게 정리합니다. */
.attendance-detail-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.attendance-detail-summary {
    display: flex;
    align-items: center;
    gap: 10px 18px;
    flex-wrap: wrap;
    margin: 8px 0 12px;
    padding: 12px 14px;
    border: 1px solid #dbe4f0;
    border-radius: 12px;
    background: #f8fafc;
    color: #334155;
    font-size: 13px;
}
.attendance-detail-summary strong {
    color: #0f2747;
}
.attendance-detail-policy-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(260px, 1fr));
    margin: 0 0 14px;
    border: 1px solid #dbe4f0;
    border-radius: 12px;
    overflow: hidden;
    background: #ffffff;
}
.attendance-detail-policy-grid > div {
    padding: 11px 14px;
    border-right: 1px solid #eef2f7;
    border-bottom: 1px solid #eef2f7;
    background: #fbfcfe;
    color: #334155;
    font-size: 13px;
}
.attendance-detail-policy-grid > div:nth-child(2n) {
    border-right: 0;
}
.attendance-detail-policy-grid strong {
    color: #0086a8;
    font-weight: 900;
}
.attendance-detail-month-summary {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin: 0 0 14px;
}
.attendance-detail-month-summary span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    min-height: 30px;
    padding: 6px 10px;
    border: 1px solid #dbeafe;
    border-radius: 999px;
    background: #f8fbff;
    color: #1e3a8a;
    font-size: 12px;
    font-weight: 750;
}
.attendance-detail-month-summary strong {
    color: #0891b2;
    font-weight: 900;
}
.attendance-detail-scroll-wrap {
    max-height: none;
}
.attendance-detail-table {
    min-width: 1280px;
}
.attendance-detail-table th,
.attendance-detail-table td {
    font-size: 12px;
    padding: 9px 8px;
    white-space: nowrap;
}
.attendance-detail-table tr.is-focus-row td {
    background: #e0f2fe !important;
    box-shadow: inset 0 1px 0 #bae6fd, inset 0 -1px 0 #bae6fd;
}
.attendance-detail-table .sat,
.attendance-detail-table td.sat {
    background: #f3f8ff !important;
}
.attendance-detail-table .sun,
.attendance-detail-table td.sun,
.attendance-detail-table .holiday,
.attendance-detail-table td.holiday {
    background: #fff7f7 !important;
}
@media (max-width: 900px) {
    .attendance-detail-actions {
        width: 100%;
        justify-content: flex-start;
    }
    .attendance-detail-policy-grid {
        grid-template-columns: 1fr;
    }
    .attendance-detail-policy-grid > div {
        border-right: 0;
    }
}
.attendance-detail-table tr.saturday-cell td {
    background: #f3f8ff !important;
}
.attendance-detail-table tr.sunday-cell td {
    background: #fff7f7 !important;
}
.attendance-detail-table tr.saturday-cell:hover td,
.attendance-detail-table tr.sunday-cell:hover td {
    background: #eaf3ff !important;
}

/* 개인 근태 상세 - 유연근무/초과시간 강조
   - 유연근무 대상자는 월 상세 상단에서 적용기간과 요일별 기준시간을 바로 확인할 수 있게 표시합니다.
   - 초과시간 관련 셀은 연한 노랑 톤으로 구분하고, 합계 행은 더 진하게 강조합니다. */
.attendance-detail-flex-section {
    margin: 0 0 14px;
    padding: 12px 14px;
    border: 1px solid #dbeafe;
    border-radius: 12px;
    background: #f8fbff;
}
.attendance-detail-section-title {
    margin-bottom: 10px;
    color: #0f2747;
    font-size: 14px;
    font-weight: 900;
}
.attendance-detail-flex-card {
    border: 1px solid #dbe4f0;
    border-radius: 12px;
    background: #ffffff;
    overflow: hidden;
}
.attendance-detail-flex-card + .attendance-detail-flex-card {
    margin-top: 10px;
}
.attendance-detail-flex-head {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    padding: 10px 12px;
    border-bottom: 1px solid #eef2f7;
    background: #f1f5f9;
    color: #334155;
    font-size: 13px;
}
.attendance-detail-flex-head strong {
    color: #0f2747;
    font-weight: 900;
}
.attendance-detail-flex-head span {
    color: #475569;
    font-weight: 700;
}
.attendance-detail-flex-days {
    display: grid;
    grid-template-columns: repeat(7, minmax(130px, 1fr));
    gap: 0;
}
.attendance-detail-flex-day {
    min-height: 74px;
    padding: 10px 9px;
    border-right: 1px solid #eef2f7;
    background: #ffffff;
}
.attendance-detail-flex-day:last-child {
    border-right: 0;
}
.attendance-detail-flex-day.is-sun {
    background: #fff7f7;
}
.attendance-detail-flex-day.is-sat {
    background: #f3f8ff;
}
.attendance-detail-flex-day-label {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    margin-bottom: 6px;
    border-radius: 999px;
    background: #e0f2fe;
    color: #075985;
    font-size: 12px;
    font-weight: 900;
}
.attendance-detail-flex-day.is-sun .attendance-detail-flex-day-label {
    background: #fee2e2;
    color: #b91c1c;
}
.attendance-detail-flex-day.is-sat .attendance-detail-flex-day-label {
    background: #dbeafe;
    color: #1d4ed8;
}
.attendance-detail-flex-day-time {
    display: block;
    color: #334155;
    font-size: 12px;
    font-weight: 750;
    line-height: 1.45;
    white-space: normal;
}
.attendance-detail-table .overtime-group-head {
    background: #fff7ed !important;
    color: #9a3412 !important;
}
.attendance-detail-table .overtime-cell {
    background: #fffbeb !important;
    color: #713f12;
    font-weight: 750;
}
.attendance-detail-table .overtime-main-cell {
    background: #fef3c7 !important;
    color: #92400e;
    font-weight: 900;
}
.attendance-detail-total-row th,
.attendance-detail-total-row td {
    border-top: 2px solid #f59e0b !important;
    background: #fff7ed !important;
    color: #0f2747;
    font-weight: 900;
}
.attendance-detail-total-row .overtime-total-cell {
    background: #fde68a !important;
    color: #78350f;
    font-size: 13px;
}
.attendance-detail-total-row .overtime-total-main {
    background: #f59e0b !important;
    color: #ffffff;
}
@media (max-width: 1100px) {
    .attendance-detail-flex-days {
        grid-template-columns: repeat(2, minmax(180px, 1fr));
    }
    .attendance-detail-flex-day {
        border-bottom: 1px solid #eef2f7;
    }
}


/* 0 또는 00:00 시간값은 거의 보이지 않도록 표시 */
.time-zero-muted,
.legacy-table td.time-zero-muted,
.basic-table td.time-zero-muted,
.attendance-table td.time-zero-muted,
.daily-attendance-table td.time-zero-muted,
.personal-attendance-table td.time-zero-muted,
.monthly-attendance-table td.time-zero-muted,
.monthly-attendance-table td.sunday-cell.time-zero-muted,
.monthly-attendance-table td.saturday-cell.time-zero-muted {
    color: rgba(100, 116, 139, 0.16) !important;
    font-weight: 400 !important;
}

.legacy-table tr:hover td.time-zero-muted,
.basic-table tr:hover td.time-zero-muted,
.attendance-table tr:hover td.time-zero-muted {
    color: rgba(100, 116, 139, 0.26) !important;
}

/* 등록/생성 레이어 박스 스타일 정리: 화면 전체 basic-table 톤과 통일 */
.legacy-register-box,
.attendance-rebuild-box {
    border: 1px solid #e2e8f0 !important;
    border-radius: 14px !important;
    background: #ffffff !important;
    box-shadow: 0 10px 28px rgba(15, 23, 42, .06) !important;
    overflow: hidden;
}

.legacy-register-title,
.attendance-rebuild-title {
    background: #f8fafc !important;
    color: #172033 !important;
    border-bottom: 1px solid #e2e8f0 !important;
    text-align: left !important;
    padding: 13px 18px !important;
    font-size: 15px !important;
    font-weight: 900 !important;
}

.legacy-register-form,
.attendance-rebuild-body {
    background: #ffffff !important;
}

.legacy-register-row {
    border-bottom: 1px solid #edf2f7 !important;
}

.attendance-rebuild-body {
    color: #334155 !important;
}

.attendance-rebuild-actions {
    border-top: 1px solid #edf2f7 !important;
    background: #fbfdff !important;
}

/* 달력/등록 영역도 파란색 강조 대신 중립 톤으로 정리 */
.deduction-calendar-panel {
    border-color: #e2e8f0 !important;
    background: #ffffff !important;
}

.deduction-calendar-week-head > .deduction-week-head-label,
.deduction-calendar-week-head > div {
    background: #f8fafc !important;
    color: #334155 !important;
    border: 1px solid #e2e8f0;
}

.deduction-calendar-day:has(input:checked) {
    border-color: #14a39a !important;
    background: #f0fdfa !important;
    color: #0f766e !important;
    box-shadow: inset 0 0 0 1px rgba(20, 163, 154, .20) !important;
}

.deduction-calendar-week-head > .deduction-week-head-label.is-sunday,
.deduction-calendar-week-head > div.is-sunday {
    background: #fff7f8 !important;
    color: #be123c !important;
    border-color: #fecdd3 !important;
}

.deduction-calendar-week-head > .deduction-week-head-label.is-saturday,
.deduction-calendar-week-head > div.is-saturday {
    background: #f8fbff !important;
    color: #1d4ed8 !important;
    border-color: #bfdbfe !important;
}


/* 등록/생성 박스 강조 스타일: 목록 테이블과 구분되는 따뜻한 톤 */
.legacy-register-box,
.attendance-rebuild-box {
    border: 1px solid #f6c76f !important;
    border-left: 6px solid #f59e0b !important;
    border-radius: 16px !important;
    background: #fffaf0 !important;
    box-shadow: 0 14px 34px rgba(146, 64, 14, .14) !important;
    overflow: hidden;
}

.legacy-register-title,
.attendance-rebuild-title {
    background: linear-gradient(135deg, #fff7ed 0%, #fffbeb 100%) !important;
    color: #7c2d12 !important;
    border-bottom: 1px solid #fed7aa !important;
    text-align: left !important;
    padding: 14px 18px !important;
    font-size: 15px !important;
    font-weight: 900 !important;
}

.legacy-register-title::before,
.attendance-rebuild-title::before {
    content: "";
    display: inline-block;
    width: 8px;
    height: 8px;
    margin-right: 8px;
    border-radius: 999px;
    background: #f59e0b;
    vertical-align: 2px;
    box-shadow: 0 0 0 4px rgba(245, 158, 11, .16);
}

.legacy-register-form,
.attendance-rebuild-body {
    background: #fffdf7 !important;
}

.legacy-register-row {
    border-bottom: 1px solid #fde7bd !important;
}

.attendance-rebuild-body {
    color: #3f2f1f !important;
}

.attendance-rebuild-body .legacy-help,
.legacy-register-box .legacy-help {
    color: #7c5f38 !important;
}

.attendance-rebuild-actions {
    border-top: 1px solid #fde7bd !important;
    background: #fff8e7 !important;
}

.attendance-rebuild-box .text-danger,
.legacy-register-box .text-danger {
    color: #c2410c !important;
}

/* 등록 폼 내부 테이블이 있는 경우에도 박스와 구분되도록 처리 */
.legacy-register-box .basic-table,
.legacy-register-box .legacy-table,
.attendance-rebuild-box .basic-table,
.attendance-rebuild-box .legacy-table {
    background: #ffffff !important;
    border-color: #f3d7a5 !important;
}

/* 초과/사후/특별공제 등록 영역이 열린 상태일 때 시각적으로 더 잘 보이도록 */
.overtime-register-box.is-open,
.attendance-register-box.is-open {
    outline: 3px solid rgba(245, 158, 11, .16);
    outline-offset: 2px;
}

/* 로그인계정 관리 화면 보정
   - 팀관리자 계정 등록 버튼이 기본 로그인 버튼 스타일과 겹치지 않도록 별도 스타일을 둡니다.
   - 등록/수정 화면은 담당부서와 접근 가능 메뉴 선택 영역이 넓게 보이도록 전체 폭을 사용합니다.
   - 비밀번호 재발행 확인은 브라우저 confirm 대신 체크온 스타일 레이어로 표시합니다. */
.login-account-list-card .login-account-add-btn {
    min-width: 170px;
    min-height: 42px;
    padding: 10px 18px;
    border: 1px solid #102f4f;
    border-radius: 12px;
    background: #102f4f;
    color: #ffffff;
    font-size: 14px;
    font-weight: 850;
    line-height: 1.2;
    text-decoration: none;
    box-shadow: 0 10px 20px rgba(16,47,79,.14);
}

.login-account-list-card .login-account-add-btn:hover {
    background: #0b253f;
    color: #ffffff;
}

.login-account-form-card {
    width: 100%;
    max-width: none;
    padding: 28px;
}

.login-account-form {
    width: 100%;
    max-width: none;
}

.login-account-form .form-row-2 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.login-account-form .form-control {
    max-width: none;
}

.checkbox-grid.login-scope-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 10px;
    margin-top: 10px;
}

.checkbox-card {
    display: flex;
    gap: 9px;
    align-items: flex-start;
    padding: 11px 13px;
    border: 1px solid #dbe3ef;
    border-radius: 13px;
    background: #ffffff;
    color: #1f2937;
    line-height: 1.35;
}

.checkbox-card:hover {
    border-color: #b8c6d8;
    background: #f8fafc;
}

.checkbox-card input {
    margin-top: 3px;
}

.checkbox-card small {
    color: #64748b;
    font-size: 12px;
}

.checkbox-card-all {
    margin-top: 8px;
    border-color: #b7c7dd;
    background: #f3f7fc;
}

.menu-checkbox-grid .checkbox-card {
    min-height: 62px;
}

.check-confirm-layer {
    position: fixed;
    inset: 0;
    z-index: 10020;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.check-confirm-layer.is-visible {
    display: flex;
}

.check-confirm-dim {
    position: absolute;
    inset: 0;
    background: rgba(15,23,42,.54);
}

.check-confirm-box {
    position: relative;
    width: min(470px, calc(100vw - 32px));
    overflow: hidden;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 24px 60px rgba(15,23,42,.28);
    outline: none;
}

.check-confirm-head {
    display: grid;
    grid-template-columns: 36px 1fr 32px;
    align-items: center;
    gap: 10px;
    padding: 24px 24px 12px;
}

.check-confirm-icon {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: #fff1f2;
    color: #e11d48;
    font-weight: 900;
}

.check-confirm-title {
    margin: 0;
    color: #111827;
    font-size: 21px;
    font-weight: 900;
    letter-spacing: -.04em;
}

.check-confirm-x {
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: #6b7280;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
}

.check-confirm-x:hover {
    background: #f3f4f6;
    color: #111827;
}

.check-confirm-message {
    padding: 10px 28px 24px 70px;
    color: #374151;
    font-size: 16px;
    line-height: 1.65;
    word-break: keep-all;
}

.check-confirm-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 18px 22px;
    border-top: 1px solid #eef2f7;
    background: #f8fafc;
}

.check-confirm-cancel,
.check-confirm-ok {
    min-width: 94px;
    height: 46px;
    padding: 0 18px;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 850;
    cursor: pointer;
}

.check-confirm-cancel {
    border: 1px solid #d1d5db;
    background: #ffffff;
    color: #374151;
}

.check-confirm-ok {
    border: 1px solid #102f4f;
    background: #102f4f;
    color: #ffffff;
}

.check-confirm-ok:disabled {
    opacity: .6;
    cursor: not-allowed;
}

@media (max-width: 760px) {
    .login-account-form .form-row-2 {
        grid-template-columns: 1fr;
    }

    .check-confirm-message {
        padding-left: 28px;
    }
}

/* 2026-05-02 footer width/height alignment and login account email verification */
.site-footer {
    background: #f7f7f8;
    border-top: 1px solid #d6d6d8;
    color: #777b82;
}

.footer-top-line {
    width: min(1520px, calc(100% - 40px));
    height: 3px;
    margin: 0 auto;
    background: #102f4f;
}

.site-footer-inner {
    width: min(1520px, calc(100% - 40px));
    max-width: none;
    min-height: 72px;
    margin: 0 auto;
    padding: 16px 0 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.footer-logo {
    width: 38px;
    height: 38px;
}

.footer-title {
    font-size: 18px;
}

.email-verify-panel {
    margin-top: 10px;
    padding: 14px;
    border: 1px solid #dbeafe;
    border-radius: 14px;
    background: #f8fbff;
}

.email-verify-head {
    margin-bottom: 10px;
    display: flex;
    flex-direction: column;
    gap: 3px;
    color: #1f2937;
    font-size: 13px;
    line-height: 1.45;
}

.email-verify-head strong {
    font-size: 14px;
    color: #102f4f;
}

.email-verify-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-email-verify {
    height: 46px;
    min-width: 132px;
    flex: 0 0 auto;
    font-size: 14px;
}

.email-verify-code {
    flex: 1 1 auto;
    max-width: 180px;
    text-align: center;
    letter-spacing: .18em;
    font-weight: 800;
}

.email-verify-message {
    margin-top: 8px;
}

.email-verify-message.is-success {
    color: #047857;
}

.email-verify-message.is-error {
    color: #b91c1c;
}

@media (max-width: 700px) {
    .footer-top-line,
    .site-footer-inner {
        width: calc(100% - 24px);
    }

    .site-footer-inner {
        align-items: flex-start;
        flex-direction: column;
        gap: 12px;
    }

    .email-verify-row {
        align-items: stretch;
        flex-direction: column;
    }

    .email-verify-code {
        max-width: none;
        text-align: left;
        letter-spacing: normal;
    }
}

/* 로그인 이메일 2차인증 영역입니다. */
.login-verify-group {
    margin-top: 4px;
}

.login-verify-row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 8px;
    align-items: center;
}

.login-verify-send {
    min-width: 128px;
    height: 52px;
    white-space: nowrap;
}

.login-verify-help.is-success {
    color: #047857;
    font-weight: 700;
}

.login-verify-help.is-error {
    color: #b91c1c;
    font-weight: 700;
}

.two-factor-method-group .form-control:disabled {
    background: #f3f4f6;
    color: #6b7280;
}

@media (max-width: 640px) {
    .login-verify-row {
        grid-template-columns: 1fr;
    }

    .login-verify-send {
        width: 100%;
    }
}

/* 로그인계정 관리 버튼 배치 보정
   - 목록 테이블 안의 관리 버튼은 일반 버튼보다 작게 표시합니다.
   - 수정/비밀번호 재발행/잠금 초기화가 서로 겹치지 않도록 flex-wrap으로 정렬합니다.
   - form을 inline으로 억지 배치하지 않고 버튼 크기만큼만 차지하게 합니다. */
.login-account-actions-cell {
    min-width: 230px;
    width: 250px;
}
.login-account-row-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 6px;
}
.login-account-row-actions form {
    display: inline-flex;
    margin: 0;
}
.login-account-row-actions .btn-secondary-mini {
    min-width: auto;
    height: 32px;
    min-height: 32px;
    padding: 0 10px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 800;
    white-space: nowrap;
}
.login-account-row-actions .btn-secondary-mini:hover {
    transform: none;
}
@media (max-width: 1200px) {
    .login-account-actions-cell {
        min-width: 190px;
        width: 210px;
    }
    .login-account-row-actions {
        justify-content: flex-start;
    }
}

/* 플라이SMS ON 추가 스타일 */
.sms-message-grid {
    display: grid;
    grid-template-columns: minmax(320px, 1.12fr) minmax(280px, .88fr);
    gap: 22px;
    align-items: start;
}
.sms-form-card,
.sms-side-card {
    padding: 24px;
}
.sms-textarea-large {
    min-height: 190px !important;
    padding-top: 12px !important;
    resize: vertical;
    line-height: 1.55;
}
.sms-recipients-box {
    min-height: 130px !important;
    padding-top: 12px !important;
    resize: vertical;
    line-height: 1.55;
}

.sms-recipient-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 7px;
}
.sms-recipient-label-row label {
    margin-bottom: 0;
}
.sms-recipient-count-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    background: #f1f5f9;
    color: #64748b;
    font-size: 12px;
    font-weight: 900;
    white-space: nowrap;
}
.sms-recipient-count-badge.has-recipients {
    background: #e0f2fe;
    color: #075985;
}
.sms-counter-row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-top: 7px;
    color: #6b7280;
    font-size: 12px;
    line-height: 1.45;
}
.sms-counter-strong {
    color: #102f4f;
    font-weight: 850;
}
.sms-send-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 18px;
}
.sms-mini-stat {
    padding: 14px 15px;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    background: #f8fafc;
}
.sms-mini-stat span {
    display: block;
    color: #6b7280;
    font-size: 12px;
    font-weight: 750;
}
.sms-mini-stat strong {
    display: block;
    margin-top: 4px;
    color: #111827;
    font-size: 20px;
    font-weight: 900;
    letter-spacing: -0.04em;
}
.sms-preview-box {
    min-height: 240px;
    padding: 18px;
    border: 1px solid #d9e2ef;
    border-radius: 18px;
    background: linear-gradient(180deg, #f8fbff, #ffffff);
}
.sms-phone-preview {
    max-width: 320px;
    margin: 0 auto;
    padding: 18px 14px;
    border: 1px solid #d1d5db;
    border-radius: 24px;
    background: #f3f4f6;
    box-shadow: inset 0 0 0 4px #fff;
}
.sms-bubble-title {
    margin: 0 0 8px;
    color: #102f4f;
    font-size: 13px;
    font-weight: 900;
}
.sms-bubble {
    max-height: 260px;
    overflow-y: auto;
    padding: 13px 14px;
    border-radius: 16px;
    background: #ffffff;
    color: #111827;
    font-size: 14px;
    line-height: 1.55;
    white-space: pre-wrap;
    word-break: break-all;
    box-shadow: 0 8px 20px rgba(15, 23, 42, .08);
}
.sms-image-list {
    margin: 10px 0 0;
    padding: 0;
    list-style: none;
    color: #4b5563;
    font-size: 12px;
    line-height: 1.55;
    word-break: break-all;
}
.sms-result-code {
    margin-top: 12px;
    padding: 12px 14px;
    border-radius: 12px;
    background: #0f172a;
    color: #d1d5db;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: 12px;
    line-height: 1.55;
    white-space: pre-wrap;
    overflow-x: auto;
}
.sms-hidden {
    display: none !important;
}
.sms-api-key-text {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    letter-spacing: .04em;
}
.sms-recent-list {
    display: grid;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.sms-recent-item {
    padding: 12px 13px;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    background: #fff;
    color: #4b5563;
    font-size: 13px;
    line-height: 1.55;
}
.sms-recent-item strong {
    color: #111827;
}
@media (max-width: 980px) {
    .sms-message-grid,
    .sms-send-summary {
        grid-template-columns: 1fr;
    }
}

/* 플라이SMS ON 2026-05-09: 로그인/명단/환경설정 확장 */
.text-uppercase { text-transform: uppercase; }
.header-user-role { color:#6b7280; font-size:12px; font-weight:700; }
.sms-dashboard-hero { max-width:none; }
.sms-stat-grid,
.sms-send-summary,
.sms-setting-summary { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; margin:16px 0 18px; }
.sms-mini-stat,
.sms-setting-summary > div { padding:15px 16px; border:1px solid #e5e7eb; border-radius:14px; background:#f8fafc; }
.sms-mini-stat span,
.sms-setting-summary span { display:block; margin-bottom:6px; color:#64748b; font-size:12px; font-weight:800; }
.sms-mini-stat strong,
.sms-setting-summary strong { color:#111827; font-size:20px; font-weight:900; letter-spacing:-.03em; }
.sms-setting-summary strong { font-size:15px; }
.sms-dashboard-menu-grid { margin-bottom:22px; }
.sms-member-grid { grid-template-columns:minmax(320px,430px) minmax(0,1fr); }
.sms-settings-grid { grid-template-columns:minmax(320px,430px) minmax(0,1fr); }
.sms-search-bar { display:grid; grid-template-columns:minmax(180px,1fr) 160px 120px auto auto; }
.inline-form { display:inline-flex; margin:0; }
.btn-table { min-width:auto; height:34px; padding:0 10px; border-radius:9px; font-size:12px; }
.sms-sender-form { padding:14px; margin-bottom:16px; border:1px solid #e5e7eb; border-radius:14px; background:#f8fafc; }
.sms-sender-table { min-width:700px; }
.sms-message-grid { display:grid; grid-template-columns:minmax(0,1fr) 380px; gap:22px; align-items:start; }
.sms-form-card,
.sms-preview-card { min-width:0; }
.sms-recipients-box { min-height:118px !important; }
.sms-text-box { min-height:180px !important; }
.sms-mms-url + .sms-mms-url { margin-top:8px; }
.sms-hidden { display:none !important; }
.sms-phone-preview { padding:18px; border-radius:22px; background:#111827; color:#fff; }
.sms-phone-header { margin-bottom:14px; color:#cbd5e1; font-size:13px; font-weight:850; }
.sms-phone-bubble { min-height:140px; padding:14px; border-radius:18px 18px 18px 4px; background:#f8fafc; color:#111827; white-space:pre-wrap; line-height:1.55; font-size:14px; }
.sms-preview-images { margin:12px 0 0; padding-left:18px; color:#dbeafe; font-size:12px; line-height:1.7; }
.sms-member-picker { margin-top:22px; }
.sms-member-picker-head { display:flex; align-items:center; justify-content:space-between; gap:10px; margin-bottom:10px; }
.sms-member-picker-head h3 { margin:0; font-size:15px; font-weight:900; color:#111827; }
.sms-check-all { display:inline-flex; align-items:center; gap:7px; margin-bottom:8px; color:#374151; font-size:13px; font-weight:800; }
.sms-member-list { max-height:320px; overflow:auto; border:1px solid #e5e7eb; border-radius:14px; background:#fff; }
.sms-member-item { min-height:42px; display:grid; grid-template-columns:24px minmax(0,1fr) auto; align-items:center; gap:8px; padding:8px 10px; border-bottom:1px solid #f1f5f9; cursor:pointer; }
.sms-member-item:last-child { border-bottom:0; }
.sms-member-item:hover { background:#f8fafc; }
.sms-member-name { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; color:#111827; font-size:13px; font-weight:850; }
.sms-member-phone { color:#64748b; font-size:12px; font-weight:700; }
.sms-result-code { overflow:auto; max-height:360px; padding:14px; border-radius:12px; background:#0f172a; color:#e2e8f0; font-size:12px; line-height:1.55; }
@media (max-width:1080px) {
    .sms-message-grid,
    .sms-member-grid,
    .sms-settings-grid { grid-template-columns:1fr; }
    .sms-stat-grid,
    .sms-send-summary,
    .sms-setting-summary { grid-template-columns:repeat(2,minmax(0,1fr)); }
    .sms-search-bar { grid-template-columns:1fr; }
}
@media (max-width:640px) {
    .sms-stat-grid,
    .sms-send-summary,
    .sms-setting-summary { grid-template-columns:1fr; }
}

/* SMS 문자발송 화면 단순화 */
.sms-send-main-row {
    grid-template-columns: minmax(180px, 260px) minmax(220px, 1fr);
    align-items: start;
}
.sms-result-card .alert {
    margin-bottom: 0;
}
.sms-result-detail {
    margin-top: 12px;
}
.sms-result-detail > summary {
    cursor: pointer;
    color: #374151;
    font-size: 13px;
    font-weight: 850;
}
.sms-advanced-options {
    margin: 16px 0 18px;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    background: #f8fafc;
}
.sms-advanced-options > summary {
    padding: 13px 15px;
    cursor: pointer;
    color: #102f4f;
    font-size: 14px;
    font-weight: 900;
    list-style-position: inside;
}
.sms-advanced-options[open] > summary {
    border-bottom: 1px solid #e5e7eb;
}
.sms-advanced-options .form-group {
    padding: 15px;
}
.sms-advanced-options .form-group:last-child {
    margin-bottom: 0;
}
@media (max-width: 760px) {
    .sms-send-main-row {
        grid-template-columns: 1fr;
    }
}

.login-save-id {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 2px 0 18px;
    color: #4b5563;
    font-size: 14px;
    cursor: pointer;
}

.login-save-id input {
    width: 16px;
    height: 16px;
    margin: 0;
}

/* SMS 명단관리: 등록/수정 레이어팝업 */
.sms-member-list-card { max-width:none; }
.section-head-row { display:flex; align-items:center; justify-content:space-between; gap:12px; }
.member-form-layer { position:fixed; inset:0; z-index:1200; display:none; align-items:center; justify-content:center; padding:24px; }
.member-form-layer.is-open { display:flex; }
.member-form-dim { position:absolute; inset:0; background:rgba(15,23,42,.54); backdrop-filter:blur(2px); }
.member-form-box { position:relative; z-index:1; width:min(640px,100%); max-height:calc(100vh - 48px); overflow:auto; padding:24px; border-radius:20px; box-shadow:0 28px 70px rgba(15,23,42,.24); }
.member-form-head { display:flex; align-items:flex-start; justify-content:space-between; gap:16px; margin-bottom:16px; }
.member-form-head .page-eyebrow { margin-bottom:6px; }
.member-form-head .basic-section-title { margin-bottom:0; }
.member-form-close { width:38px; height:38px; display:inline-flex; align-items:center; justify-content:center; border:1px solid #d1d5db; border-radius:12px; background:#fff; color:#374151; font-size:24px; line-height:1; font-weight:800; cursor:pointer; }
.member-form-close:hover { background:#f8fafc; border-color:#9ca3af; }
.member-form-actions { justify-content:flex-end; padding-top:4px; }
body.member-modal-lock { overflow:hidden; }

@media (max-width:640px) {
    .member-form-layer { align-items:flex-end; padding:0; }
    .member-form-box { width:100%; max-height:92vh; border-radius:20px 20px 0 0; padding:20px; }
    .member-form-actions { align-items:stretch; flex-direction:column; }
    .member-form-actions .btn-inline,
    .member-form-actions .btn-secondary { width:100%; }
}

/* SMS 기초정보/명단 구분 선택 확장 */
.sms-basic-info-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: -8px 0 18px;
}
.sms-basic-info-tab {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 0 16px;
    border: 1px solid #dbe3ef;
    border-radius: 999px;
    background: #fff;
    color: #475569;
    font-size: 13px;
    font-weight: 850;
    text-decoration: none;
}
.sms-basic-info-tab:hover,
.sms-basic-info-tab.is-active {
    border-color: #2563eb;
    background: #eff6ff;
    color: #1d4ed8;
}
.sms-basic-info-card { max-width: none; }
.sms-basic-search-bar { grid-template-columns: minmax(220px,1fr) 140px auto auto; }
.sms-basic-info-table { min-width: 520px; }
.basic-info-form-box { width: min(520px, 100%); }
.sms-check-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    padding: 10px;
    border: 1px solid #dbe3ef;
    border-radius: 14px;
    background: #f8fafc;
}
.sms-check-option {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 38px;
    padding: 8px 10px;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    background: #fff;
    color: #111827;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
}
.sms-check-option:hover { border-color: #93c5fd; background: #eff6ff; }
.sms-check-option input { width: 16px; height: 16px; margin: 0; }
.sms-check-option.is-disabled { color: #94a3b8; background: #f8fafc; }
.compact-empty-state { padding: 14px; min-height: auto; }

@media (max-width:1080px) {
    .sms-basic-search-bar { grid-template-columns: 1fr; }
}
@media (max-width:640px) {
    .sms-basic-info-tab { flex: 1 1 auto; }
    .sms-check-grid { grid-template-columns: 1fr; }
}


/* 비밀번호 변경 화면 */
.password-change-layout {
    display: grid;
    grid-template-columns: minmax(320px, 460px) minmax(260px, 1fr);
    gap: 22px;
    align-items: start;
}

.password-change-card,
.password-guide-card {
    padding: 24px;
}

.password-change-form .btn-primary {
    margin-top: 10px;
}

.readonly-value {
    min-height: 44px;
    padding: 11px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    background: #f9fafb;
    color: #111827;
    font-size: 14px;
    font-weight: 800;
}

.readonly-value span {
    color: #6b7280;
    font-size: 13px;
    font-weight: 750;
}

.password-guide-list {
    margin: 0;
    padding-left: 18px;
    color: #4b5563;
    font-size: 14px;
    line-height: 1.9;
}

@media (max-width: 760px) {
    .password-change-layout {
        grid-template-columns: 1fr;
    }

    .readonly-value {
        align-items: flex-start;
        flex-direction: column;
        gap: 4px;
    }
}

/* SMS 문자발송: 좌측 명단 선택 / 우측 발송 입력 배치 */
.sms-send-layout {
    grid-template-columns: minmax(300px, 380px) minmax(0, 1fr);
    gap: 22px;
    align-items: start;
}
.sms-member-picker-card,
.sms-send-compose-card {
    min-width: 0;
}
.sms-member-picker-card {
    position: sticky;
    top: 18px;
}
.sms-member-picker-card .sms-member-picker {
    margin-top: 0;
}
.sms-member-picker-title-row {
    align-items: flex-start;
    margin-bottom: 14px;
}
.sms-member-picker-title-row .card-description {
    margin: 6px 0 0;
}
.sms-member-picker-card .sms-member-list {
    max-height: min(620px, calc(100vh - 280px));
}
.sms-member-limit-help {
    margin-top: 10px;
}
.sms-preview-card-inline {
    margin-top: 18px;
    padding: 16px;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    background: #f8fafc;
}
.sms-preview-card-inline h3 {
    margin: 0 0 12px;
    color: #111827;
    font-size: 15px;
    font-weight: 900;
}
.sms-preview-card-inline .sms-phone-preview {
    max-width: 520px;
}
.sms-send-button-row {
    display: flex;
    justify-content: flex-end;
    margin-top: 18px;
}
.sms-send-button-row .btn-primary {
    min-width: 160px;
}
@media (max-width: 1080px) {
    .sms-send-layout {
        grid-template-columns: 1fr;
    }
    .sms-member-picker-card {
        position: static;
    }
    .sms-member-picker-card .sms-member-list {
        max-height: 360px;
    }
}
@media (max-width: 640px) {
    .sms-send-button-row {
        align-items: stretch;
        flex-direction: column;
    }
    .sms-send-button-row .btn-primary {
        width: 100%;
    }
}

/* SMS 문자발송: 넓은 명단 선택 + 상세 검색 */
.sms-send-layout {
    grid-template-columns: minmax(520px, 1.35fr) minmax(360px, .9fr);
}
.sms-member-picker-card .sms-member-picker-title-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 14px;
}
.sms-member-search-form {
    margin: 0 0 14px;
    padding: 14px;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    background: #f8fafc;
}
.sms-member-filter-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}
.sms-member-filter-grid .form-group {
    margin: 0;
}
.sms-member-filter-grid label {
    margin-bottom: 5px;
    font-size: 12px;
}
.sms-member-filter-grid .form-control {
    height: 40px;
    border-radius: 10px;
    font-size: 13px;
}
.sms-member-search-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 12px;
}
.sms-member-search-actions .btn-small {
    height: 38px;
    min-width: 72px;
    font-size: 13px;
}
.sms-member-pick-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 0 0 10px;
}
.sms-member-pick-toolbar .sms-check-all {
    margin-bottom: 0;
}
.sms-member-pick-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    margin-left: auto;
}
.sms-member-add-button {
    min-width: 96px;
    height: 38px;
    padding: 0 18px;
    border-radius: 999px;
    background: #f97316;
    box-shadow: 0 10px 18px rgba(249, 115, 22, 0.22);
    font-size: 13px;
    font-weight: 900;
}
.sms-member-add-button:hover {
    background: #ea580c;
}
.sms-member-result-count {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    background: #eef2ff;
    color: #3730a3;
    font-size: 12px;
    font-weight: 900;
    white-space: nowrap;
}
.sms-member-picker-card .sms-member-list {
    max-height: min(660px, calc(100vh - 365px));
}
.sms-member-item {
    min-height: 56px;
    grid-template-columns: 24px minmax(0, 1fr) minmax(104px, auto);
    gap: 10px;
    padding: 10px 12px;
}
.sms-member-main {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.sms-member-main .sms-member-name {
    display: block;
}
.sms-member-meta {
    display: block;
    overflow: hidden;
    color: #64748b;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.sms-member-empty-help {
    margin: 14px 0 0;
    padding: 16px;
    border: 1px dashed #cbd5e1;
    border-radius: 14px;
    background: #f8fafc;
    text-align: center;
}
@media (max-width: 1240px) {
    .sms-send-layout {
        grid-template-columns: minmax(460px, 1.2fr) minmax(340px, .9fr);
    }
    .sms-member-filter-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
@media (max-width: 1080px) {
    .sms-send-layout {
        grid-template-columns: 1fr;
    }
    .sms-member-picker-card .sms-member-list {
        max-height: 420px;
    }
}
@media (max-width: 640px) {
    .sms-member-picker-card .sms-member-picker-title-row,
    .sms-member-filter-grid {
        grid-template-columns: 1fr;
    }
    .sms-member-pick-toolbar {
        align-items: stretch;
        flex-direction: column;
    }
    .sms-member-pick-actions {
        align-items: stretch;
        justify-content: stretch;
        margin-left: 0;
        width: 100%;
    }
    .sms-member-result-count {
        flex: 1;
        justify-content: center;
    }
    .sms-member-add-button {
        flex: 1;
        min-width: 0;
    }
    .sms-member-search-actions {
        justify-content: stretch;
    }
    .sms-member-search-actions .btn-small {
        flex: 1;
    }
    .sms-member-item {
        grid-template-columns: 24px minmax(0, 1fr);
    }
    .sms-member-phone {
        grid-column: 2;
        justify-self: start;
    }
}

/* SMS 문자발송/명단관리/작업로그 페이징 */
.sms-member-pagination,
.work-log-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex-wrap: wrap;
    margin-top: 16px;
}
.pagination-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex-wrap: wrap;
}
.pagination-btn,
.pagination-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    border: 1px solid #dbe3ef;
    border-radius: 10px;
    background: #fff;
    color: #0f2742;
    font-size: 13px;
    font-weight: 800;
    line-height: 1;
    text-decoration: none;
    transition: background .15s ease, border-color .15s ease, color .15s ease, box-shadow .15s ease;
}
.pagination-btn {
    min-width: 58px;
    padding: 0 12px;
}
.pagination-number {
    min-width: 34px;
    padding: 0 9px;
}
.pagination-btn:hover,
.pagination-number:hover {
    border-color: #123b63;
    box-shadow: 0 8px 18px rgba(15, 39, 66, .08);
}
.pagination-number.is-active {
    border-color: #123b63;
    background: #123b63;
    color: #fff;
    box-shadow: 0 8px 18px rgba(18, 59, 99, .18);
}
.pagination-btn.is-disabled,
.pagination-number.is-disabled,
.btn-ghost.is-disabled {
    opacity: .45;
    pointer-events: none;
}
.sms-member-page-state {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    padding: 0 12px;
    border-radius: 999px;
    background: #f1f5f9;
    color: #334155;
    font-size: 13px;
    font-weight: 800;
}
.work-log-search-form {
    margin: 0 0 16px;
    padding: 14px;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    background: #f8fafc;
}
.work-log-filter-grid {
    grid-template-columns: minmax(220px, 1.2fr) repeat(4, minmax(140px, .8fr));
}
.work-log-summary-row {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 10px;
}
.work-log-table td {
    vertical-align: top;
}
.work-log-detail summary {
    cursor: pointer;
    color: #2563eb;
    font-size: 12px;
    font-weight: 900;
}
.work-log-detail dl {
    display: grid;
    gap: 6px;
    margin: 8px 0 0;
    min-width: 260px;
}
.work-log-detail dt {
    color: #64748b;
    font-size: 11px;
    font-weight: 900;
}
.work-log-detail dd {
    margin: 0;
    color: #334155;
    font-size: 12px;
    line-height: 1.55;
    word-break: break-all;
}
.work-log-detail pre {
    max-width: 420px;
    max-height: 180px;
    overflow: auto;
    margin: 0;
    padding: 10px;
    border-radius: 10px;
    background: #0f172a;
    color: #e2e8f0;
    font-size: 11px;
    white-space: pre-wrap;
}
.muted-text {
    color: #64748b;
    font-size: 12px;
    font-weight: 700;
}
@media (max-width: 1080px) {
    .work-log-filter-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
@media (max-width: 640px) {
    .sms-member-pagination,
    .work-log-pagination {
        justify-content: flex-start;
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 4px;
    }
    .pagination-numbers {
        flex-wrap: nowrap;
    }
    .pagination-btn {
        min-width: 54px;
        padding: 0 10px;
    }
    .pagination-number {
        min-width: 32px;
        padding: 0 8px;
    }
    .sms-member-pagination .pagination-number:not(.is-mobile-visible-5) {
        display: none;
    }
    .sms-member-page-state {
        justify-content: center;
    }
    .work-log-filter-grid {
        grid-template-columns: 1fr;
    }
}


@media (max-width: 420px) {
    .sms-member-pagination {
        gap: 4px;
    }
    .sms-member-pagination .pagination-number.is-mobile-visible-5:not(.is-mobile-visible-3) {
        display: none;
    }
    .sms-member-pagination .pagination-btn {
        min-width: 46px;
        padding: 0 8px;
        font-size: 12px;
    }
    .sms-member-pagination .pagination-number {
        min-width: 30px;
        padding: 0 7px;
        font-size: 12px;
    }
}

/* SMS 명단관리: 검색 확장 + 페이징 */
.sms-member-manage-search-bar {
    grid-template-columns: minmax(170px, 1fr) 150px 150px 150px 120px 120px auto auto;
    align-items: center;
}
.sms-member-list-summary {
    display: flex;
    justify-content: flex-end;
    margin: 0 0 10px;
}
.sms-member-list-summary span {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 11px;
    border-radius: 999px;
    background: #f1f5f9;
    color: #334155;
    font-size: 12px;
    font-weight: 850;
}
@media (max-width: 1240px) {
    .sms-member-manage-search-bar {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}
@media (max-width: 760px) {
    .sms-member-manage-search-bar {
        grid-template-columns: 1fr;
    }
    .sms-member-list-summary {
        justify-content: flex-start;
    }
}

/* 모바일 햄버거 메뉴 */
.mobile-menu-toggle,
.mobile-user-panel {
    display: none;
}

@media (max-width: 900px) {
    .site-header-inner {
        width: calc(100% - 24px) !important;
        min-height: auto !important;
        padding: 12px 0 !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 12px !important;
    }

    .brand-link {
        min-width: 0;
    }

    .brand-logo {
        width: 36px;
        height: 36px;
        border-radius: 11px;
    }

    .brand-title {
        max-width: 180px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        font-size: 19px;
    }

    .header-menu {
        display: none !important;
    }

    .mobile-menu-toggle {
        min-width: 74px;
        min-height: 42px;
        padding: 0 13px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        border: 1px solid #cbd5e1;
        border-radius: 13px;
        background: #ffffff;
        color: #102f4f;
        font: inherit;
        font-size: 13px;
        font-weight: 900;
        letter-spacing: -0.02em;
        cursor: pointer;
        box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
    }

    .mobile-menu-toggle-lines {
        width: 18px;
        height: 14px;
        display: inline-flex;
        flex-direction: column;
        justify-content: space-between;
    }

    .mobile-menu-toggle-lines span {
        width: 100%;
        height: 2px;
        display: block;
        border-radius: 999px;
        background: currentColor;
        transition: transform .16s ease, opacity .16s ease;
    }

    .mobile-menu-toggle.is-open .mobile-menu-toggle-lines span:nth-child(1) {
        transform: translateY(6px) rotate(45deg);
    }

    .mobile-menu-toggle.is-open .mobile-menu-toggle-lines span:nth-child(2) {
        opacity: 0;
    }

    .mobile-menu-toggle.is-open .mobile-menu-toggle-lines span:nth-child(3) {
        transform: translateY(-6px) rotate(-45deg);
    }

    .top-nav {
        display: none;
        border-top: 1px solid #e2e8f0;
        background: #102f4f;
        box-shadow: 0 18px 30px rgba(15, 23, 42, 0.16);
    }

    .top-nav.is-open {
        display: block;
    }

    .top-nav-inner {
        width: calc(100% - 24px) !important;
        min-height: 0;
        padding: 12px 0 14px !important;
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 8px;
        flex-wrap: nowrap !important;
    }

    .mobile-user-panel {
        padding: 12px;
        display: block;
        border: 1px solid rgba(255, 255, 255, 0.14);
        border-radius: 16px;
        background: rgba(255, 255, 255, 0.08);
        color: #ffffff;
    }

    .mobile-user-name {
        margin-bottom: 10px;
        font-size: 14px;
        font-weight: 900;
        line-height: 1.45;
    }

    .mobile-user-name span {
        display: block;
        color: rgba(255, 255, 255, 0.72);
        font-size: 12px;
        font-weight: 750;
    }

    .mobile-user-actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }

    .mobile-user-link {
        min-height: 38px;
        padding: 0 10px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border: 1px solid rgba(255, 255, 255, 0.24);
        border-radius: 12px;
        background: rgba(255, 255, 255, 0.1);
        color: #ffffff;
        text-decoration: none;
        font-size: 13px;
        font-weight: 850;
    }

    .mobile-user-link.is-active,
    .mobile-user-link:hover {
        background: rgba(255, 255, 255, 0.18);
    }

    .mobile-logout-link {
        background: #ffffff;
        color: #102f4f;
    }

    .top-home-link,
    .top-menu-button {
        width: 100%;
        min-height: 42px;
        height: auto;
        padding: 0 13px;
        justify-content: flex-start;
        border-radius: 13px;
        background: rgba(255, 255, 255, 0.08);
        color: rgba(255, 255, 255, 0.94);
    }

    .top-home-link:hover,
    .top-home-link.is-active,
    .top-menu-group:hover .top-menu-button,
    .top-menu-group.is-active .top-menu-button,
    .top-menu-group:focus-within .top-menu-button {
        background: rgba(255, 255, 255, 0.16);
        color: #ffffff;
    }

    .top-menu-group {
        width: 100%;
        padding: 0;
        margin: 0;
    }

    .top-menu-panel {
        position: static;
        min-width: 100%;
        margin: 5px 0 0;
        padding: 7px;
        display: block !important;
        border: 0;
        border-radius: 13px;
        background: rgba(255, 255, 255, 0.96);
        box-shadow: none;
    }

    .top-menu-panel::before {
        display: none;
    }

    .top-menu-link {
        min-height: 37px;
        padding: 8px 10px;
        font-size: 13px;
    }
}

@media (max-width: 420px) {
    .brand-title {
        max-width: 130px;
        font-size: 18px;
    }

    .mobile-menu-toggle {
        min-width: 48px;
        padding: 0 12px;
    }

    .mobile-menu-toggle-text {
        display: none;
    }
}

/* SMS 문자발송: 여백 압축형 레이아웃 */
.sms-send-layout {
    gap: 16px;
}
.sms-send-layout .sms-member-picker-card,
.sms-send-layout .sms-send-compose-card {
    padding: 18px 16px;
}
.sms-send-layout .basic-section-title {
    margin-bottom: 10px;
}
.sms-member-picker-title-row {
    margin-bottom: 10px;
}
.sms-member-picker-title-row .card-description {
    margin-top: 3px;
    line-height: 1.45;
}
.sms-member-search-form {
    margin-bottom: 10px;
    padding: 10px 12px;
    border-radius: 14px;
}
.sms-member-filter-grid {
    gap: 8px;
}
.sms-member-filter-grid label {
    margin-bottom: 4px;
}
.sms-member-filter-grid .form-control {
    height: 38px;
}
.sms-member-search-actions {
    margin-top: 8px;
}
.sms-member-search-actions .btn-small {
    height: 36px;
}
.sms-member-pick-toolbar {
    margin-bottom: 8px;
}
.sms-member-picker-card .sms-member-list {
    max-height: min(700px, calc(100vh - 310px));
}
.sms-member-item {
    min-height: 48px;
    padding: 8px 12px;
}
.sms-member-main {
    gap: 2px;
}
.sms-member-meta {
    line-height: 1.25;
}
.sms-send-compose-card .compact-form .form-group {
    margin-bottom: 10px;
}
.sms-send-compose-card .form-row-2 {
    gap: 12px;
}
.sms-send-compose-card .form-help {
    margin-top: 4px;
    line-height: 1.35;
}
.sms-send-main-row {
    grid-template-columns: minmax(170px, 1fr) minmax(200px, 1fr);
}
.sms-recipient-label-row {
    margin-bottom: 5px;
}
.sms-recipient-count-badge {
    min-height: 24px;
    padding: 0 9px;
}
.sms-recipients-box {
    height: 108px;
    min-height: 108px !important;
    padding-top: 10px !important;
}
.sms-text-box {
    height: 142px;
    min-height: 142px !important;
    padding-top: 10px !important;
}
.sms-preview-card-inline {
    margin-top: 12px;
    padding: 12px;
    border-radius: 14px;
}
.sms-preview-card-inline h3 {
    margin-bottom: 8px;
}
.sms-preview-card-inline .sms-phone-preview {
    max-width: none;
    padding: 14px;
    border-radius: 18px;
}
.sms-phone-header {
    margin-bottom: 8px;
}
.sms-phone-bubble {
    min-height: 90px;
    max-height: 160px;
    padding: 12px;
    font-size: 13px;
    line-height: 1.45;
    overflow-y: auto;
}
.sms-preview-images {
    margin-top: 8px;
}
.sms-advanced-options {
    margin: 12px 0;
}
.sms-advanced-options > summary {
    padding: 11px 13px;
}
.sms-send-button-row {
    margin-top: 12px;
}
@media (min-width: 1320px) {
    .sms-member-filter-grid {
        grid-template-columns: minmax(120px, 1fr) minmax(120px, 1fr) minmax(120px, 1fr) minmax(120px, 1fr) minmax(120px, 1fr) 112px;
    }
}
@media (max-width: 640px) {
    .sms-send-layout .sms-member-picker-card,
    .sms-send-layout .sms-send-compose-card {
        padding: 16px 14px;
    }
    .sms-recipients-box {
        height: 96px;
        min-height: 96px !important;
    }
    .sms-text-box {
        height: 128px;
        min-height: 128px !important;
    }
}

/* SMS 문자발송: 명단관리형 한 줄 선택 리스트 */
.sms-member-auto-help {
    margin: -2px 0 8px;
    color: #2563eb;
    font-weight: 800;
}
.sms-send-member-table {
    overflow: hidden;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    background: #fff;
}
.sms-send-member-head,
.sms-send-member-row {
    display: grid;
    grid-template-columns: 42px minmax(88px, 1fr) minmax(110px, 1.1fr) minmax(92px, .9fr) minmax(110px, auto);
    align-items: center;
    gap: 10px;
    text-align: center;
}
.sms-send-member-head {
    padding: 9px 12px;
    border-bottom: 1px solid #e5e7eb;
    background: #f8fafc;
    color: #475569;
    font-size: 12px;
    font-weight: 900;
}
.sms-member-picker-card .sms-send-member-list {
    max-height: min(690px, calc(100vh - 335px));
    border: 0;
    border-radius: 0;
}
.sms-send-member-row {
    min-height: 42px;
    padding: 8px 12px;
    grid-template-columns: 42px minmax(88px, 1fr) minmax(110px, 1.1fr) minmax(92px, .9fr) minmax(110px, auto);
}
.sms-send-member-row.is-selected {
    background: #eff6ff;
}
.sms-send-member-row.is-selected:hover {
    background: #dbeafe;
}
.sms-member-check-cell {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.sms-send-member-row .sms-member-name,
.sms-send-member-row .sms-member-dept,
.sms-send-member-row .sms-member-level,
.sms-send-member-row .sms-member-phone {
    min-width: 0;
    overflow: hidden;
    text-align: center;
    text-overflow: ellipsis;
    white-space: nowrap;
    justify-self: center;
    line-height: 1.3;
}
.sms-send-member-row .sms-member-name {
    color: #111827;
    font-size: 13px;
    font-weight: 900;
}
.sms-send-member-row .sms-member-dept,
.sms-send-member-row .sms-member-level {
    color: #475569;
    font-size: 12px;
    font-weight: 750;
}
.sms-send-member-row .sms-member-phone {
    color: #475569;
    font-size: 12px;
    font-weight: 850;
}
@media (max-width: 640px) {
    .sms-send-member-head {
        display: none;
    }
    .sms-send-member-row {
        grid-template-columns: 28px minmax(0, 1fr) minmax(96px, auto);
        gap: 8px;
        min-height: 46px;
    }
    .sms-send-member-row .sms-member-dept,
    .sms-send-member-row .sms-member-level {
        grid-column: 2;
        font-size: 11px;
    }
    .sms-send-member-row .sms-member-dept::after {
        content: ' ·';
    }
    .sms-send-member-row .sms-member-level {
        margin-top: -18px;
        padding-left: min(55%, 150px);
    }
    .sms-send-member-row .sms-member-phone {
        grid-column: 3;
        grid-row: 1 / span 3;
        align-self: center;
        justify-self: end;
    }
}
@media (max-width: 640px) {
    .sms-send-member-row .sms-member-dept::after { content: ''; }
    .sms-send-member-row .sms-member-level {
        margin-top: 0;
        padding-left: 0;
    }
}

/* SMS 문자발송: MMS 이미지 업로드 */
.sms-mms-upload-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
/*
 * file input은 브라우저 기본 버튼의 높이·baseline이 일반 input과 달라
 * padding만 지정하면 버튼과 파일명 텍스트가 위아래로 어긋날 수 있습니다.
 * 입력창과 버튼 높이를 명시해 한 줄 중앙 정렬로 고정합니다.
 */
.sms-mms-file {
    display: block;
    width: 100%;
    height: 44px !important;
    min-height: 44px;
    box-sizing: border-box;
    padding: 4px 12px !important;
    line-height: 34px;
    cursor: pointer;
}
.sms-mms-file::file-selector-button,
.sms-mms-file::-webkit-file-upload-button {
    width: auto;
    height: 34px;
    min-height: 34px;
    box-sizing: border-box;
    margin: 0 12px 0 0;
    padding: 0 13px;
    border: 0;
    border-radius: 10px;
    background: #0f365c;
    color: #fff;
    font-size: 14px;
    font-weight: 900;
    line-height: 34px;
    vertical-align: middle;
    cursor: pointer;
}
@media (max-width: 640px) {
    .sms-mms-file {
        height: 42px !important;
        min-height: 42px;
        padding: 4px 10px !important;
        font-size: 13px;
        line-height: 32px;
    }
    .sms-mms-file::file-selector-button,
    .sms-mms-file::-webkit-file-upload-button {
        height: 32px;
        min-height: 32px;
        margin-right: 10px;
        padding: 0 11px;
        font-size: 13px;
        line-height: 32px;
    }
}

/* SMS 문자발송: 외부 엑셀 명단 업로드 */
.sms-excel-upload-panel {
    margin-bottom: 12px;
    padding: 12px;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    background: #f8fafc;
}
.sms-excel-upload-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 8px;
}
.sms-subsection-title {
    margin: 0 0 3px;
    color: #111827;
    font-size: 14px;
    font-weight: 900;
}
.sms-excel-guide-box {
    margin-bottom: 10px;
    padding: 10px 12px;
    border: 1px solid #dbeafe;
    border-radius: 12px;
    background: #fff;
    color: #334155;
    font-size: 12px;
    line-height: 1.5;
}
.sms-excel-guide-box p {
    margin: 3px 0 0;
}
.sms-excel-guide-blue {
    color: #1d4ed8;
    font-weight: 900;
}
.sms-excel-upload-form {
    margin: 0;
}
.sms-excel-upload-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    align-items: center;
}
.sms-excel-upload-row input[type="file"].form-control {
    height: 42px;
    min-height: 42px;
    padding: 5px 10px;
    line-height: 30px;
    display: block;
    font-size: 13px;
}
.sms-excel-upload-row input[type="file"].form-control::file-selector-button {
    height: 30px;
    margin: 0 10px 0 0;
    padding: 0 12px;
    border: 1px solid #94a3b8;
    border-radius: 8px;
    background: #ffffff;
    color: #111827;
    font-size: 13px;
    font-weight: 800;
    line-height: 28px;
    cursor: pointer;
}
.sms-excel-upload-row input[type="file"].form-control::-webkit-file-upload-button {
    height: 30px;
    margin: 0 10px 0 0;
    padding: 0 12px;
    border: 1px solid #94a3b8;
    border-radius: 8px;
    background: #ffffff;
    color: #111827;
    font-size: 13px;
    font-weight: 800;
    line-height: 28px;
    cursor: pointer;
}
.sms-excel-preview-panel {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px dashed #cbd5e1;
}
.sms-excel-preview-toolbar {
    align-items: center;
    margin-bottom: 6px;
}
.sms-excel-summary-help {
    margin: 0 0 7px;
    color: #b45309;
    font-weight: 800;
}
.sms-excel-recipient-table {
    overflow: hidden;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    background: #fff;
}
.sms-excel-recipient-head,
.sms-excel-recipient-row {
    display: grid;
    grid-template-columns: 42px minmax(92px, 1fr) minmax(118px, auto) 70px;
    align-items: center;
    gap: 8px;
    text-align: center;
}
.sms-excel-recipient-head {
    padding: 8px 10px;
    border-bottom: 1px solid #e5e7eb;
    background: #f1f5f9;
    color: #475569;
    font-size: 12px;
    font-weight: 900;
}
.sms-excel-recipient-list {
    max-height: 240px;
    overflow-y: auto;
}
.sms-excel-recipient-row {
    min-height: 38px;
    padding: 7px 10px;
    border-bottom: 1px solid #eef2f7;
    cursor: pointer;
    transition: background-color .15s ease;
}
.sms-excel-recipient-row:last-child {
    border-bottom: 0;
}
.sms-excel-recipient-row:hover {
    background: #f8fafc;
}
.sms-excel-recipient-row.is-selected {
    background: #eff6ff;
}
.sms-excel-recipient-name,
.sms-excel-recipient-phone,
.sms-excel-recipient-status {
    min-width: 0;
    overflow: hidden;
    text-align: center;
    text-overflow: ellipsis;
    white-space: nowrap;
    justify-self: center;
    line-height: 1.25;
}
.sms-excel-recipient-name {
    color: #111827;
    font-size: 13px;
    font-weight: 900;
}
.sms-excel-recipient-phone {
    color: #475569;
    font-size: 12px;
    font-weight: 850;
}
.sms-excel-recipient-status {
    padding: 3px 6px;
    border-radius: 999px;
    background: #f1f5f9;
    color: #475569;
    font-size: 11px;
    font-weight: 900;
}
.sms-excel-recipient-status.is-corrected {
    background: #fef3c7;
    color: #92400e;
}
.btn-tiny {
    min-height: 28px;
    padding: 6px 9px;
    border-radius: 8px;
    font-size: 12px;
}
@media (max-width: 640px) {
    .sms-excel-upload-panel {
        padding: 10px;
    }
    .sms-excel-upload-row {
        grid-template-columns: 1fr;
    }
    .sms-excel-recipient-head {
        display: none;
    }
    .sms-excel-recipient-row {
        grid-template-columns: 30px minmax(0, 1fr) minmax(104px, auto);
    }
    .sms-excel-recipient-status {
        grid-column: 2;
        justify-self: center;
    }
}

/* SMS 문자발송: 보조 버튼 색상 구분 */
.sms-member-picker-card .sms-excel-upload-head .btn-secondary.btn-tiny {
    border-color: #15803d !important;
    background: #16a34a !important;
    color: #ffffff !important;
    box-shadow: 0 8px 18px rgba(22, 163, 74, .20) !important;
}
.sms-member-picker-card .sms-excel-upload-head .btn-secondary.btn-tiny:hover {
    border-color: #166534 !important;
    background: #15803d !important;
    color: #ffffff !important;
}
.sms-member-picker-card .sms-excel-upload-row .btn-secondary {
    border-color: #2563eb !important;
    background: #2563eb !important;
    color: #ffffff !important;
    box-shadow: 0 8px 18px rgba(37, 99, 235, .18) !important;
}
.sms-member-picker-card .sms-excel-upload-row .btn-secondary:hover {
    border-color: #1d4ed8 !important;
    background: #1d4ed8 !important;
    color: #ffffff !important;
}
.sms-member-picker-card .sms-excel-preview-toolbar .btn-ghost.btn-tiny {
    border-color: #fb7185 !important;
    background: #fff1f2 !important;
    color: #be123c !important;
}
.sms-member-picker-card .sms-excel-preview-toolbar .btn-ghost.btn-tiny:hover {
    border-color: #e11d48 !important;
    background: #ffe4e6 !important;
    color: #9f1239 !important;
}
.sms-member-picker-card .sms-member-search-actions .btn-secondary {
    border-color: #0f3a63 !important;
    background: #0f3a63 !important;
    color: #ffffff !important;
    box-shadow: 0 8px 18px rgba(15, 58, 99, .18) !important;
}
.sms-member-picker-card .sms-member-search-actions .btn-secondary:hover {
    border-color: #0b2c4a !important;
    background: #0b2c4a !important;
    color: #ffffff !important;
}
.sms-member-picker-card .sms-member-search-actions .btn-ghost {
    border-color: #94a3b8 !important;
    background: #f1f5f9 !important;
    color: #334155 !important;
}
.sms-member-picker-card .sms-member-search-actions .btn-ghost:hover {
    border-color: #64748b !important;
    background: #e2e8f0 !important;
    color: #1e293b !important;
}

@media (max-width: 640px) {
    .sms-member-picker-card .sms-excel-upload-head .btn-secondary.btn-tiny,
    .sms-member-picker-card .sms-excel-upload-row .btn-secondary,
    .sms-member-picker-card .sms-excel-preview-toolbar .btn-ghost.btn-tiny,
    .sms-member-picker-card .sms-member-search-actions .btn-secondary,
    .sms-member-picker-card .sms-member-search-actions .btn-ghost {
        min-height: 36px !important;
    }
}

/* SMS 문자발송: 엑셀 개별 내용 발송 모드 */
.sms-excel-sample-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    justify-content: flex-end;
}
.sms-send-mode-toggle {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin: 0 0 10px;
}
.sms-send-mode-option {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 38px;
    padding: 8px 10px;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    background: #ffffff;
    color: #334155;
    font-size: 12px;
    font-weight: 900;
    cursor: pointer;
    transition: border-color .15s ease, background-color .15s ease, color .15s ease, box-shadow .15s ease;
}
.sms-send-mode-option input {
    width: 14px;
    height: 14px;
    margin: 0;
}
.sms-send-mode-option.is-active {
    border-color: #0f3a63;
    background: #eff6ff;
    color: #0f3a63;
    box-shadow: 0 8px 18px rgba(15, 58, 99, .10);
}
.sms-member-picker-card .sms-excel-upload-head .sms-excel-sample-personal.btn-secondary.btn-tiny {
    border-color: #7c3aed !important;
    background: #7c3aed !important;
    box-shadow: 0 8px 18px rgba(124, 58, 237, .20) !important;
}
.sms-member-picker-card .sms-excel-upload-head .sms-excel-sample-personal.btn-secondary.btn-tiny:hover {
    border-color: #6d28d9 !important;
    background: #6d28d9 !important;
}
.sms-excel-recipient-table.is-personal-mode {
    overflow-x: auto;
}
.sms-excel-recipient-table.is-personal-mode .sms-excel-recipient-head,
.sms-excel-recipient-row.is-personal-mode {
    grid-template-columns: 42px minmax(76px, .7fr) 112px minmax(76px, .7fr) minmax(180px, 1.5fr) 62px 64px;
    min-width: 760px;
}
.sms-excel-recipient-title,
.sms-excel-recipient-text,
.sms-excel-recipient-bytes {
    min-width: 0;
    overflow: hidden;
    text-align: center;
    text-overflow: ellipsis;
    white-space: nowrap;
    justify-self: center;
    line-height: 1.25;
}
.sms-excel-recipient-title {
    color: #475569;
    font-size: 12px;
    font-weight: 850;
}
.sms-excel-recipient-text {
    color: #111827;
    font-size: 12px;
    font-weight: 750;
    max-width: 100%;
}
.sms-excel-recipient-bytes {
    color: #2563eb;
    font-size: 12px;
    font-weight: 900;
}
.sms-personal-message-notice {
    margin: 10px 0 12px;
    padding: 12px 14px;
    border: 1px solid #bfdbfe;
    border-radius: 12px;
    background: #eff6ff;
    color: #1e3a8a;
    font-size: 13px;
    font-weight: 800;
    line-height: 1.5;
}
@media (max-width: 640px) {
    .sms-excel-upload-head {
        flex-direction: column;
        align-items: stretch;
    }
    .sms-excel-sample-actions,
    .sms-send-mode-toggle {
        grid-template-columns: 1fr;
    }
    .sms-excel-sample-actions {
        display: grid;
        justify-content: stretch;
    }
    .sms-excel-sample-actions .btn-tiny {
        width: 100%;
    }
    .sms-excel-recipient-table.is-personal-mode .sms-excel-recipient-head {
        display: grid;
    }
    .sms-excel-recipient-row.is-personal-mode {
        grid-template-columns: 42px minmax(76px, .7fr) 112px minmax(76px, .7fr) minmax(180px, 1.5fr) 62px 64px;
    }
}

/* ========================================================================
   SMS 발송로그 / 월별집계 화면 보정
   - 신규 조회폼 클래스와 월별 집계 전용 테이블 클래스의 스타일이 누락되어
     입력항목이 세로로 풀리고 SMS/LMS/MMS 구분색이 사라진 문제를 보완합니다.
   ======================================================================== */
.sms-log-search-bar,
.sms-summary-search-bar {
    display: grid;
    align-items: end;
    gap: 14px 12px;
    margin: 0;
}

.sms-log-search-bar {
    grid-template-columns: repeat(5, minmax(0, 1fr));
}

.sms-summary-search-bar {
    grid-template-columns: repeat(4, minmax(150px, 1fr));
}

.sms-log-search-bar .form-group,
.sms-summary-search-bar .form-group {
    min-width: 0;
    margin: 0;
}

.sms-log-search-bar label,
.sms-summary-search-bar label {
    display: block;
    margin: 0 0 7px;
    color: #334155;
    font-size: 13px;
    font-weight: 850;
}

.sms-log-search-bar .form-control,
.sms-summary-search-bar .form-control {
    width: 100%;
    min-width: 0;
    height: 44px;
    padding: 0 12px;
    border-radius: 11px;
    font-size: 14px;
}

.sms-log-search-bar .compact-date,
.sms-log-search-bar .compact-input,
.sms-log-search-bar .compact-select,
.sms-summary-search-bar .compact-date {
    width: 100%;
    min-width: 0;
}

.sms-log-search-bar .btn-primary,
.sms-summary-search-bar .btn-primary {
    width: 100%;
    min-width: 0;
    height: 44px;
    margin: 0;
    padding: 0 18px;
    border-radius: 11px;
    align-self: end;
    font-size: 14px;
}

/* 발송로그 목록: 시간/번호/메시지 컬럼이 좁아지지 않도록 가로 스크롤을 유지합니다. */
.sms-log-table-wrap,
.sms-agent-log-table-wrap {
    overflow-x: auto;
}

.sms-log-table,
.sms-agent-log-table {
    min-width: 1240px;
}

.sms-log-table td,
.sms-agent-log-table td {
    white-space: nowrap;
}

.sms-log-message {
    min-width: 220px;
    max-width: 360px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sms-page-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 18px;
}

.sms-page-current {
    min-width: 92px;
    color: #334155;
    text-align: center;
    font-size: 13px;
    font-weight: 850;
}

/* 월별 집계표: SMS/LMS/MMS를 서로 다른 계열의 색으로 구분합니다. */
.sms-monthly-summary-table-wrap {
    overflow-x: auto;
    background: #ffffff;
}

.sms-monthly-summary-table {
    min-width: 900px;
    table-layout: fixed;
}

.sms-monthly-summary-table th,
.sms-monthly-summary-table td {
    padding: 11px 10px;
    text-align: center;
    white-space: nowrap;
}

.sms-monthly-summary-table .summary-date-head,
.sms-monthly-summary-table .summary-date-cell {
    width: 148px;
}

.sms-monthly-summary-table .summary-date-head {
    background: #f1f5f9 !important;
    color: #334155;
}

.sms-monthly-summary-table .summary-date-cell {
    color: #334155;
    font-weight: 800;
}

.sms-monthly-summary-table .summary-group-head {
    border-bottom: 1px solid rgba(148, 163, 184, .32);
    font-size: 13px;
    font-weight: 900;
}

.sms-monthly-summary-table .summary-subhead {
    font-size: 12px;
    font-weight: 850;
}

/* SMS — blue */
.sms-monthly-summary-table .summary-group-sms {
    background: #dbeafe !important;
    color: #1d4ed8;
}
.sms-monthly-summary-table .summary-cell-sms {
    background: #f8fbff !important;
    color: #1e40af;
}
.sms-monthly-summary-table thead .summary-cell-sms {
    background: #eff6ff !important;
    color: #1d4ed8;
}
.sms-monthly-summary-table tbody tr:hover .summary-cell-sms {
    background: #e9f2ff !important;
}

/* LMS — amber */
.sms-monthly-summary-table .summary-group-lms {
    background: #ffedd5 !important;
    color: #c2410c;
}
.sms-monthly-summary-table .summary-cell-lms {
    background: #fffaf3 !important;
    color: #9a3412;
}
.sms-monthly-summary-table thead .summary-cell-lms {
    background: #fff7ed !important;
    color: #c2410c;
}
.sms-monthly-summary-table tbody tr:hover .summary-cell-lms {
    background: #fff1df !important;
}

/* MMS — violet */
.sms-monthly-summary-table .summary-group-mms {
    background: #ede9fe !important;
    color: #6d28d9;
}
.sms-monthly-summary-table .summary-cell-mms {
    background: #fbfaff !important;
    color: #6b21a8;
}
.sms-monthly-summary-table thead .summary-cell-mms {
    background: #f5f3ff !important;
    color: #6d28d9;
}
.sms-monthly-summary-table tbody tr:hover .summary-cell-mms {
    background: #f1edff !important;
}

/* 합계 — navy / 금액 — green */
.sms-monthly-summary-table .summary-group-total {
    background: #dbeafe !important;
    color: #0f3a63;
}
.sms-monthly-summary-table .summary-cell-total {
    background: #f4f8fc !important;
    color: #0f3a63;
    font-weight: 850;
}
.sms-monthly-summary-table thead .summary-cell-total {
    background: #eaf3fb !important;
}
.sms-monthly-summary-table tbody tr:hover .summary-cell-total {
    background: #e7f1f9 !important;
}
.sms-monthly-summary-table .summary-group-billing {
    background: #dcfce7 !important;
    color: #166534;
}
.sms-monthly-summary-table .summary-cell-billing {
    background: #f5fff8 !important;
    color: #166534;
    font-weight: 800;
}
.sms-monthly-summary-table thead .summary-cell-billing {
    background: #ecfdf3 !important;
}
.sms-monthly-summary-table tbody tr:hover .summary-cell-billing {
    background: #e8faee !important;
}

.sms-monthly-summary-table .summary-group-start {
    border-left: 1px solid #cbd5e1 !important;
}

.sms-monthly-summary-table .summary-zero {
    color: #94a3b8 !important;
}

.sms-monthly-summary-table tfoot .summary-grand-total-row th,
.sms-monthly-summary-table tfoot .summary-grand-total-row td {
    border-top: 2px solid #94a3b8;
    font-weight: 900;
}

.sms-monthly-summary-table tfoot .summary-grand-total-label {
    background: #e2e8f0 !important;
    color: #0f172a;
}

@media (max-width: 1120px) {
    .sms-log-search-bar {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (max-width: 840px) {
    .sms-log-search-bar,
    .sms-summary-search-bar {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 560px) {
    .sms-log-search-bar,
    .sms-summary-search-bar {
        grid-template-columns: 1fr;
        gap: 11px;
    }

    .sms-log-search-bar .btn-primary,
    .sms-summary-search-bar .btn-primary {
        width: 100%;
    }

    .sms-page-nav {
        align-items: stretch;
        flex-direction: column;
    }

    .sms-page-nav .page-action-link {
        width: 100%;
    }
}

/* SMS 문자발송: 수신자 선택 방식 3단 분리 */
.sms-recipient-source-panel {
    margin: 0 0 12px;
    padding: 12px;
    border: 1px solid #dbe3ef;
    border-radius: 14px;
    background: #f8fafc;
}
.sms-recipient-source-title {
    margin: 0 0 8px;
    color: #334155;
    font-size: 13px;
    font-weight: 900;
}
.sms-recipient-source-toggle {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}
.sms-recipient-source-option {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 42px;
    padding: 8px 10px;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    background: #ffffff;
    color: #475569;
    font-size: 12px;
    font-weight: 900;
    line-height: 1.35;
    text-align: center;
    cursor: pointer;
    transition: border-color .15s ease, background-color .15s ease, color .15s ease, box-shadow .15s ease;
}
.sms-recipient-source-option input {
    width: 14px;
    height: 14px;
    flex: 0 0 auto;
    margin: 0;
}
.sms-recipient-source-option.is-active {
    border-color: #0f3a63;
    background: #eff6ff;
    color: #0f3a63;
    box-shadow: 0 8px 18px rgba(15, 58, 99, .10);
}
.sms-recipient-source-option:hover {
    border-color: #7c9bb8;
    background: #f8fbff;
}
@media (max-width: 820px) {
    .sms-recipient-source-toggle {
        grid-template-columns: 1fr;
    }
    .sms-recipient-source-option {
        justify-content: flex-start;
        min-height: 40px;
        padding: 9px 12px;
        text-align: left;
    }
}
.sms-recipient-source-card {
    margin-bottom: 14px;
}
.sms-recipient-source-card .sms-recipient-source-panel {
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
}

.sms-member-search-result.is-loading {
    opacity: 0.58;
    pointer-events: none;
}
