html, body {
    font-family: 'Malgun Gothic', 'Apple SD Gothic Neo', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    margin: 0;
    height: 100%;
}

h1:focus {
    outline: none;
}

.blazor-error-boundary {
    background: #b32121;
    padding: 1rem;
    color: white;
}

.blazor-error-boundary::after {
    content: "오류가 발생했습니다.";
}

/* ─── 공통 셸 ─────────────────────────────── */
.hm-shell {
    display: flex;
    flex-direction: column;
    height: 100vh;
}

.hm-topbar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 16px;
    height: 52px;
    background: #2c5aa0;
    color: #fff;
    flex-shrink: 0;
}

.hm-brand {
    font-size: 1.15rem;
    font-weight: 700;
}

.hm-spacer { flex: 1; }

.hm-user { font-size: .9rem; opacity: .9; }

.hm-logout-form { margin: 0; }

.hm-logout-btn {
    background: rgba(255,255,255,.15);
    border: 1px solid rgba(255,255,255,.4);
    color: #fff;
    border-radius: 4px;
    padding: 4px 12px;
    cursor: pointer;
    font-size: .85rem;
}
.hm-logout-btn:hover { background: rgba(255,255,255,.28); }

.hm-main {
    flex: 1;
    min-height: 0;
}

/* ─── 메일함 3단 레이아웃 ─────────────────── */
.hm-mail {
    display: grid;
    grid-template-columns: 210px 400px 1fr;
    height: 100%;
    min-height: 0;
}

.hm-compose-btn-wrap { padding: 4px 12px 12px; }

.hm-compose-btn {
    width: 100%;
    background: #2c5aa0;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 10px;
    font-size: .95rem;
    font-weight: 700;
    cursor: pointer;
}
.hm-compose-btn:hover { background: #244b86; }

/* 폴더 */
.hm-folders {
    border-right: 1px solid #dde3ea;
    background: #f7f9fb;
    overflow-y: auto;
    padding: 10px 0;
}

.hm-folders ul { list-style: none; margin: 0; padding: 0; }

.hm-folders li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 9px 14px;
    cursor: pointer;
    font-size: .95rem;
}
.hm-folders li:hover { background: #e9eff7; }
.hm-folders li.active { background: #dbe7f5; font-weight: 700; }
.hm-folders li.hm-folder-dragover { background: #cfe6d0; outline: 2px dashed #2c9a3a; }
.hm-msgs li[draggable="true"] { cursor: grab; }

.hm-badge {
    background: #e5484d;
    color: #fff;
    border-radius: 10px;
    font-size: .75rem;
    padding: 1px 7px;
}

.hm-folder-acts { display: inline-flex; align-items: center; gap: 4px; }
.hm-folder-act {
    cursor: pointer;
    font-size: .8rem;
    opacity: .35;
    padding: 0 1px;
}
.hm-folders li:hover .hm-folder-act { opacity: .75; }
.hm-folder-act:hover { opacity: 1; }

.hm-folder-rename {
    flex: 1;
    min-width: 0;
    border: 1px solid #2c5aa0;
    border-radius: 4px;
    padding: 3px 6px;
    font-size: .88rem;
}

.hm-folder-add { padding: 8px 12px; }
.hm-folder-addbtn {
    background: none;
    border: 1px dashed #b6c2d0;
    border-radius: 6px;
    color: #6b7684;
    padding: 6px 10px;
    width: 100%;
    cursor: pointer;
    font-size: .85rem;
}
.hm-folder-addbtn:hover { background: #eef3f9; color: #2c5aa0; border-color: #2c5aa0; }

/* 메일 목록 */
.hm-list {
    border-right: 1px solid #dde3ea;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.hm-list-head {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 10px;
    border-bottom: 1px solid #dde3ea;
    background: #fff;
    flex-shrink: 0;
}

.hm-paging { display: flex; align-items: center; gap: 6px; font-size: .85rem; color: #555; }

.hm-btn {
    background: #fff;
    border: 1px solid #c9d3de;
    border-radius: 4px;
    padding: 4px 10px;
    cursor: pointer;
    font-size: .85rem;
}
.hm-btn:hover:not(:disabled) { background: #eef3f9; }
.hm-btn:disabled { opacity: .45; cursor: default; }

.hm-msgs {
    list-style: none;
    margin: 0;
    padding: 0;
    overflow-y: auto;
    flex: 1;
}

.hm-msg {
    padding: 9px 12px;
    border-bottom: 1px solid #eef1f5;
    cursor: pointer;
}
.hm-msg:hover { background: #f4f8fd; }
.hm-msg.unread { background: #fbfdff; }
.hm-msg-focused { box-shadow: inset 3px 0 0 #2c5aa0; background: #eef4fb; }
.hm-msg.unread .hm-msg-from,
.hm-msg.unread .hm-msg-subject { font-weight: 700; }

.hm-msg-line1, .hm-msg-line2 {
    display: flex;
    justify-content: space-between;
    gap: 8px;
}

.hm-msg-from {
    font-size: .9rem;
    color: #222;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.hm-msg-date { font-size: .8rem; color: #888; flex-shrink: 0; }

.hm-msg-folder {
    font-size: .72rem;
    background: #e8eef6;
    color: #46617f;
    border-radius: 3px;
    padding: 0 6px;
    margin-left: auto;
    margin-right: 6px;
    flex-shrink: 0;
}

.hm-searchopts {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 8px 12px;
    background: #f4f8fd;
    border-bottom: 1px solid #dde3ea;
    font-size: .85rem;
    flex-wrap: wrap;
}
.hm-searchopts label { display: flex; align-items: center; gap: 6px; color: #555; }

.hm-msg-subject {
    font-size: .88rem;
    color: #444;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.hm-msg-meta { font-size: .78rem; color: #999; flex-shrink: 0; }

.hm-thread-count {
    background: #2c5aa0;
    color: #fff;
    border-radius: 9px;
    font-size: .72rem;
    padding: 0 7px;
    flex-shrink: 0;
}

.hm-thread-child {
    padding-left: 24px !important;
    background: #fbfcfe;
    border-left: 3px solid #dbe3ec;
}

.hm-msg-preview {
    font-size: .8rem;
    color: #9aa5b1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin-top: 2px;
}
.hm-msg.unread .hm-msg-preview { color: #7a8794; }

/* 본문 */
.hm-view {
    display: flex;
    flex-direction: column;
    min-height: 0;
    background: #fff;
}

.hm-view-head {
    padding: 14px 18px;
    border-bottom: 1px solid #dde3ea;
    flex-shrink: 0;
}

.hm-view-head h2 { margin: 0 0 8px; font-size: 1.15rem; }

.hm-view-meta { font-size: .85rem; color: #555; display: grid; gap: 2px; }
.hm-view-meta b { display: inline-block; width: 64px; color: #888; font-weight: 600; }

.hm-attachments { margin-top: 10px; display: flex; flex-wrap: wrap; gap: 8px; }

.hm-attachment {
    border: 1px solid #c9d3de;
    border-radius: 4px;
    padding: 4px 10px;
    font-size: .85rem;
    text-decoration: none;
    color: #2c5aa0;
    background: #f7f9fb;
}
.hm-attachment:hover { background: #e9eff7; }

.hm-imgblock {
    margin-top: 10px;
    background: #fff8e1;
    border: 1px solid #f0dc9c;
    border-radius: 4px;
    padding: 8px 12px;
    font-size: .85rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.hm-body {
    flex: 1;
    overflow: auto;
    padding: 18px;
}

.hm-body img { max-width: 100%; }

.hm-plaintext {
    white-space: pre-wrap;
    font-family: inherit;
    margin: 0;
}

/* ─── 메일쓰기 ────────────────────────────── */
.hm-compose {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 0;
    background: #fff;
}

.hm-compose-head {
    display: flex;
    gap: 8px;
    align-items: center;
    padding: 10px 14px;
    border-bottom: 1px solid #dde3ea;
    flex-shrink: 0;
}

.hm-btn-primary {
    background: #2c5aa0;
    color: #fff;
    border-color: #2c5aa0;
    font-weight: 700;
}
.hm-btn-primary:hover:not(:disabled) { background: #244b86; }

.hm-autosave { font-size: .78rem; color: #9aa5b1; margin-left: 6px; }

.hm-schedule {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: .82rem;
    color: #555;
}
.hm-schedule input {
    border: 1px solid #c9d3de;
    border-radius: 4px;
    padding: 4px 6px;
    font-size: .82rem;
}

.hm-sendbar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    background: #eaf3ff;
    border-bottom: 1px solid #b9d4f0;
    font-size: .9rem;
    color: #234;
}

.hm-compose-fields {
    display: grid;
    gap: 6px;
    padding: 10px 14px;
    border-bottom: 1px solid #eef1f5;
    flex-shrink: 0;
}

.hm-compose-fields label {
    display: grid;
    grid-template-columns: 70px 1fr;
    align-items: center;
    font-size: .85rem;
    color: #666;
}

.hm-compose-fields input {
    border: 1px solid #c9d3de;
    border-radius: 4px;
    padding: 7px 10px;
    font-size: .9rem;
}

.hm-toolbar {
    display: flex;
    gap: 4px;
    padding: 6px 14px;
    border-bottom: 1px solid #eef1f5;
    flex-shrink: 0;
}

.hm-toolbar { flex-wrap: wrap; }

.hm-toolbar button {
    background: #fff;
    border: 1px solid #c9d3de;
    border-radius: 4px;
    padding: 3px 10px;
    cursor: pointer;
    font-size: .85rem;
}
.hm-toolbar button:hover { background: #eef3f9; }

.hm-tb-select {
    border: 1px solid #c9d3de;
    border-radius: 4px;
    padding: 3px 4px;
    font-size: .82rem;
}
.hm-tb-color {
    width: 28px;
    height: 26px;
    padding: 0;
    border: 1px solid #c9d3de;
    border-radius: 4px;
    cursor: pointer;
}
.hm-tb-linkinput {
    border: 1px solid #2c5aa0;
    border-radius: 4px;
    padding: 3px 8px;
    font-size: .82rem;
    width: 160px;
}
.hm-tb-img {
    background: #fff;
    border: 1px solid #c9d3de;
    border-radius: 4px;
    padding: 3px 10px;
    cursor: pointer;
    font-size: .85rem;
    display: inline-flex;
    align-items: center;
}
.hm-tb-img:hover { background: #eef3f9; }

.hm-editor {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 14px 16px;
    outline: none;
    font-size: .95rem;
    line-height: 1.6;
}

.hm-compose-attach {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px 14px;
    border-top: 1px solid #dde3ea;
    flex-shrink: 0;
}

.hm-file-label { display: inline-block; cursor: pointer; }

.hm-attach-hint { font-size: .78rem; color: #999; }

.hm-attach-remove {
    cursor: pointer;
    color: #b32121;
    margin-left: 4px;
    font-weight: 700;
}

.hm-view-actions {
    display: flex;
    gap: 6px;
    margin-bottom: 10px;
}

.hm-notice {
    margin: 10px;
    padding: 10px 14px;
    background: #e8f5ec;
    border: 1px solid #a9d8b8;
    border-radius: 4px;
    color: #1c7c3c;
    font-size: .85rem;
}

/* ─── 목록 확장 (선택/별표/검색/일괄작업) ── */
.hm-msg {
    display: flex;
    align-items: stretch;
    gap: 6px;
}

.hm-msg-ctrl {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    flex-shrink: 0;
}

.hm-msg-mainarea { flex: 1; min-width: 0; cursor: pointer; }

.hm-star {
    cursor: pointer;
    color: #ccc;
    font-size: 1rem;
    line-height: 1;
    user-select: none;
}
.hm-star.on { color: #f5b301; }
.hm-star:hover { color: #f5b301; }

.hm-search {
    border: 1px solid #c9d3de;
    border-radius: 4px;
    padding: 4px 10px;
    font-size: .85rem;
    width: 170px;
}

.hm-actionbar {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    background: #eef4fb;
    border-bottom: 1px solid #dde3ea;
    flex-wrap: wrap;
    flex-shrink: 0;
}

.hm-sel-count { font-size: .85rem; color: #2c5aa0; font-weight: 700; }

.hm-move-select {
    border: 1px solid #c9d3de;
    border-radius: 4px;
    padding: 4px 6px;
    font-size: .85rem;
}

/* 쿼터 */
.hm-quota {
    padding: 12px 14px;
    border-top: 1px solid #dde3ea;
    font-size: .78rem;
    color: #777;
}

.hm-quota-bar {
    height: 6px;
    background: #e2e8f0;
    border-radius: 3px;
    margin-bottom: 5px;
    overflow: hidden;
}

.hm-quota-fill {
    height: 100%;
    background: #2c5aa0;
    border-radius: 3px;
}
.hm-quota-fill.danger { background: #e5484d; }

/* ─── 상단 내비게이션 ─────────────────────── */
.hm-nav { display: flex; gap: 4px; margin-left: 18px; }

.hm-nav a {
    color: rgba(255,255,255,.85);
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: .92rem;
}
.hm-nav a:hover { background: rgba(255,255,255,.15); color: #fff; }

/* ─── 일반 페이지 (주소록/설정) ───────────── */
.hm-page {
    max-width: 860px;
    margin: 0 auto;
    padding: 24px 20px;
    overflow-y: auto;
    height: 100%;
    box-sizing: border-box;
}

.hm-page h2 { margin: 0 0 16px; font-size: 1.3rem; }

.hm-tabs { display: flex; gap: 4px; margin-bottom: 16px; border-bottom: 2px solid #dde3ea; }

.hm-tabs button {
    background: none;
    border: none;
    padding: 9px 18px;
    font-size: .95rem;
    cursor: pointer;
    color: #666;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
}
.hm-tabs button.active { color: #2c5aa0; font-weight: 700; border-bottom-color: #2c5aa0; }

.hm-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.hm-table th {
    text-align: left;
    padding: 8px 10px;
    background: #f7f9fb;
    border-bottom: 2px solid #dde3ea;
    color: #555;
    font-size: .82rem;
}
.hm-table td { padding: 8px 10px; border-bottom: 1px solid #eef1f5; }
.hm-table a { color: #2c5aa0; text-decoration: none; }
.hm-table a:hover { text-decoration: underline; }

.hm-contact-add {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}
.hm-contact-add input {
    border: 1px solid #c9d3de;
    border-radius: 4px;
    padding: 7px 10px;
    font-size: .88rem;
    flex: 1;
    min-width: 120px;
}

.hm-contact-toolbar {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
    flex-wrap: wrap;
    font-size: .85rem;
    color: #555;
}
.hm-contact-toolbar a.hm-btn { text-decoration: none; color: #2c5aa0; }

.hm-settings-sec {
    background: #fff;
    border: 1px solid #dde3ea;
    border-radius: 8px;
    padding: 18px 20px;
    margin-bottom: 18px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: flex-start;
}
.hm-settings-sec h3 { margin: 0; font-size: 1.05rem; }

.hm-hint { margin: 0; font-size: .82rem; color: #888; }

.hm-input, .hm-textarea {
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #c9d3de;
    border-radius: 4px;
    padding: 8px 10px;
    font-size: .9rem;
    font-family: inherit;
}

.hm-check { font-size: .9rem; display: flex; align-items: center; gap: 6px; }

.hm-signature { color: #666; font-size: .9em; }

/* ─── 추가 이미지 / EML 뷰어 ──────────────── */
.hm-extra-sep { margin: 18px 0 10px; border: 0; border-top: 1px dashed #c9d3de; }

.hm-extra-images { display: flex; flex-wrap: wrap; gap: 12px; }

.hm-extra-img { margin: 0; }
.hm-extra-img img { max-width: 380px; max-height: 300px; border: 1px solid #e2e8f0; border-radius: 4px; }
.hm-extra-img figcaption { font-size: .75rem; color: #999; margin-top: 3px; }

.hm-eml-view {
    border: 1px solid #dde3ea;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
}
.hm-eml-view .hm-body { max-height: 60vh; }

.hm-attachment a { color: #2c5aa0; text-decoration: none; }
.hm-attachment a:hover { text-decoration: underline; }

/* ─── 관리자 ─────────────────────────────── */
.hm-admin { max-width: 1100px; }

.hm-row-inactive { opacity: .45; }

.hm-cell-actions { display: flex; gap: 4px; flex-wrap: wrap; }

.hm-btn-danger {
    background: #e5484d;
    color: #fff;
    border-color: #e5484d;
    font-weight: 700;
}

.hm-pwbox {
    background: #fff8e1;
    border: 1px solid #f0dc9c;
    border-radius: 6px;
    padding: 12px 16px;
    margin-bottom: 14px;
    font-size: .92rem;
}
.hm-pwbox code {
    background: #333;
    color: #7CFC00;
    padding: 3px 10px;
    border-radius: 4px;
    font-size: 1.05rem;
    letter-spacing: 1px;
    user-select: all;
}

/* 상태 표시 */
.hm-loading, .hm-empty {
    padding: 30px;
    text-align: center;
    color: #999;
    font-size: .9rem;
}

.hm-loading::before {
    content: "";
    display: inline-block;
    width: 15px;
    height: 15px;
    border: 2px solid #c9d3de;
    border-top-color: #2c5aa0;
    border-radius: 50%;
    margin-right: 8px;
    vertical-align: -3px;
    animation: hmspin .8s linear infinite;
}

@keyframes hmspin {
    to { transform: rotate(360deg); }
}

.hm-btn-active {
    background: #dbe7f5;
    border-color: #2c5aa0;
    color: #2c5aa0;
    font-weight: 700;
}

.hm-inline-input {
    border: 1px solid #c9d3de;
    border-radius: 4px;
    padding: 5px 8px;
    font-size: .85rem;
    width: 100%;
    box-sizing: border-box;
}

.hm-back-btn { display: none; }

/* ─── 모바일 반응형 ───────────────────────── */
@media (max-width: 820px) {
    .hm-back-btn { display: inline-block; }

    .hm-mail { display: flex; flex-direction: column; }

    /* 폴더: 상단 가로 스크롤 바로 전환 */
    .hm-folders {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 4px;
        overflow-x: auto;
        border-right: none;
        border-bottom: 1px solid #dde3ea;
        padding: 6px 8px;
        flex-shrink: 0;
    }
    .hm-folders ul { display: flex; flex-direction: row; gap: 2px; }
    .hm-folders li { padding: 7px 10px; white-space: nowrap; border-radius: 14px; }
    .hm-compose-btn-wrap { padding: 0; flex-shrink: 0; }
    .hm-compose-btn { width: auto; padding: 8px 12px; font-size: .85rem; border-radius: 14px; }
    .hm-quota { display: none; }

    /* 목록/본문: 한 화면씩 전환 */
    .hm-list { flex: 1; min-height: 0; border-right: none; }
    .hm-view { display: none; }
    .hm-mail.hm-detail-open .hm-folders,
    .hm-mail.hm-detail-open .hm-list { display: none; }
    .hm-mail.hm-detail-open .hm-view { display: flex; flex: 1; min-height: 0; }

    /* 상단바 압축 */
    .hm-user { display: none; }
    .hm-nav { margin-left: 6px; gap: 0; }
    .hm-nav a { padding: 6px 7px; font-size: .84rem; }
    .hm-brand { font-size: 1rem; }

    /* 목록 헤더 압축 */
    .hm-search { width: 110px; }
    .hm-list-head { flex-wrap: wrap; }

    /* 표는 가로 스크롤 */
    .hm-table { display: block; overflow-x: auto; }

    .hm-page { padding: 14px 10px; }
    .hm-body { padding: 12px; }
    .hm-view-head { padding: 10px 12px; }
}

.hm-error {
    margin: 10px;
    padding: 10px 14px;
    background: #fdecec;
    border: 1px solid #f5b5b5;
    border-radius: 4px;
    color: #b32121;
    font-size: .85rem;
}

/* ─── 로그인 ─────────────────────────────── */
.hm-login-wrap {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #2c5aa0, #1d3c6e);
}

.hm-login-box {
    background: #fff;
    border-radius: 10px;
    padding: 36px 32px;
    width: 340px;
    box-shadow: 0 10px 40px rgba(0,0,0,.25);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.hm-login-box h1 { margin: 0; font-size: 1.5rem; text-align: center; }

.hm-login-sub { margin: 0 0 8px; text-align: center; color: #888; font-size: .9rem; }

.hm-login-box input {
    border: 1px solid #c9d3de;
    border-radius: 6px;
    padding: 11px 12px;
    font-size: .95rem;
}
.hm-login-box input:focus { outline: 2px solid #2c5aa0; border-color: transparent; }

.hm-login-box button {
    background: #2c5aa0;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 11px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    margin-top: 4px;
}
.hm-login-box button:hover { background: #244b86; }

.hm-login-error {
    background: #fdecec;
    border: 1px solid #f5b5b5;
    border-radius: 6px;
    padding: 9px 12px;
    color: #b32121;
    font-size: .85rem;
}

.hm-login-idrow { display: flex; align-items: center; gap: 6px; }
.hm-login-idrow .hm-login-id { flex: 1 1 52%; min-width: 0; }
.hm-login-idrow .hm-login-at { color: #888; }
.hm-login-idrow .hm-login-domain {
    flex: 1 1 48%;
    min-width: 0;
    background: #eef1f5;      /* 자동입력된 도메인은 옅게 — '읽기 전용' 느낌 */
    color: #555;
    cursor: pointer;
}
/* 클릭해 편집 모드가 되면(=readonly 해제) 일반 입력칸처럼 */
.hm-login-idrow .hm-login-domain:not([readonly]),
.hm-login-idrow .hm-login-domain-edit {
    background: #fff;
    color: inherit;
    cursor: text;
}
.hm-login-hint {
    font-size: .74rem;
    color: #8a8a8a;
    line-height: 1.5;
    margin-top: -6px;
}
.hm-login-hint b { color: #2c5aa0; font-weight: 700; }

.hm-apply-link {
    text-align: center;
    color: #2c5aa0;
    font-size: .85rem;
    text-decoration: none;
    margin-top: 4px;
}
.hm-apply-link:hover { text-decoration: underline; }

/* ─── 계정 신청 ───────────────────────────── */
.hm-apply-wrap {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #2c5aa0, #1d3c6e);
    padding: 24px 12px;
    box-sizing: border-box;
}

.hm-apply-box {
    background: #fff;
    border-radius: 10px;
    padding: 30px 28px;
    width: 400px;
    max-width: 100%;
    box-shadow: 0 10px 40px rgba(0,0,0,.25);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.hm-apply-box h1 { margin: 0; font-size: 1.35rem; text-align: center; }
.hm-apply-sub { margin: 0 0 6px; text-align: center; color: #888; font-size: .82rem; line-height: 1.5; }

.hm-apply-field { display: flex; flex-direction: column; gap: 4px; }
.hm-apply-field label { font-size: .82rem; color: #555; font-weight: 600; }
.hm-apply-field input, .hm-apply-field select, .hm-apply-field textarea {
    border: 1px solid #c9d3de;
    border-radius: 6px;
    padding: 9px 10px;
    font-size: .9rem;
    font-family: inherit;
    box-sizing: border-box;
}
.hm-apply-field input:focus, .hm-apply-field select:focus, .hm-apply-field textarea:focus {
    outline: 2px solid #2c5aa0;
    border-color: transparent;
}

.hm-apply-idrow { display: flex; align-items: center; gap: 6px; }
.hm-apply-idrow input { flex: 1; }
.hm-apply-idrow span { color: #888; }
.hm-apply-idrow select { max-width: 55%; }

.hm-captcha-row { display: flex; align-items: center; gap: 8px; }
.hm-captcha-img {
    border: 1px solid #c9d3de;
    border-radius: 6px;
    height: 56px;
    background: #f5f7fa;
}

.hm-apply-submit {
    background: #2c5aa0;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 12px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    margin-top: 4px;
}
.hm-apply-submit:hover:not(:disabled) { background: #244b86; }
.hm-apply-submit:disabled { opacity: .6; cursor: default; }
