/*
    다국어 맞춤형 법령정보 목록 (UI-A-10-01-01)

    intl-main.css 토큰(.intl-shell / .intl-sub-heading / .intl-breadcrumb / .intl-select /
    .intl-sr-only)을 재사용한다. 논리 속성으로 RTL 대응.
*/

.intl-custom-law {
    padding-block: 8px 64px;
}

/* 상단 안내 */
.intl-custom-law__guide {
    margin-block: 24px 0;
    padding: 18px 20px;
    border: 1px solid #dfe4ec;
    border-radius: 12px;
    background: #fff;
}

.intl-custom-law__guide ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.intl-custom-law__guide li {
    position: relative;
    padding-inline-start: 14px;
    color: #3d4757;
    font-size: .92rem;
    line-height: 1.6;
}

.intl-custom-law__guide li::before {
    content: "";
    position: absolute;
    inset-inline-start: 0;
    top: .72em;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: #246beb;
}

/* ① 검색 */
.intl-custom-law__search {
    margin-block: 20px 28px;
    padding: 18px 20px;
    border: 1px solid #dfe4ec;
    border-radius: 12px;
    background: #f7f9fc;
}

.intl-custom-law__search h2 {
    margin: 0 0 10px;
    color: #172033;
    font-size: .95rem;
}

.intl-custom-law__search form {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.intl-custom-law__search input[type="search"] {
    flex: 1 1 240px;
    min-width: 0;
    height: 44px;
    padding-inline: 14px;
    border: 1px solid #c5cedb;
    border-radius: 8px;
    background: #fff;
    font: inherit;
}

.intl-custom-law__btn-search,
.intl-custom-law__btn-reset {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 88px;
    height: 44px;
    padding-inline: 16px;
    border: 1px solid transparent;
    border-radius: 8px;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}

.intl-custom-law__btn-search {
    background: #246beb;
    color: #fff;
}

.intl-custom-law__btn-search:hover,
.intl-custom-law__btn-search:focus-visible {
    background: #1a5ad0;
}

.intl-custom-law__btn-reset {
    background: #fff;
    border-color: #c5cedb;
    color: #172033;
}

.intl-custom-law__btn-reset:hover,
.intl-custom-law__btn-reset:focus-visible {
    border-color: #246beb;
    color: #2266df;
}

/* ② 목록 */
.intl-custom-law__result-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-block-end: 14px;
}

.intl-custom-law__result-head h2 {
    margin: 0;
    color: #172033;
    font-size: 1rem;
}

.intl-custom-law__result-head h2 strong {
    margin-inline-start: 6px;
    color: #2266df;
}

/* 좁은 화면에서 표가 넘칠 때는 표만 가로 스크롤한다(본문은 가로 스크롤하지 않는다). */
.intl-custom-law__table-wrap {
    overflow-x: auto;
}

.intl-custom-law__table {
    width: 100%;
    min-width: 640px;
    border-collapse: collapse;
    border-block-start: 2px solid #172033;
}

.intl-custom-law__table caption {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.intl-custom-law__table th,
.intl-custom-law__table td {
    padding: 14px 10px;
    border-block-end: 1px solid #e8edf4;
    color: #172033;
    font-size: .92rem;
    text-align: center;
    word-break: break-word;
}

.intl-custom-law__table thead th {
    background: #f2f5fa;
    font-weight: 700;
}

/* 표 공통 가운데 정렬(.intl-custom-law__table td)보다 강해야 제목 칸이 왼쪽에 붙는다.
   종전 .intl-custom-law__title 단독 선택자는 그 규칙에 밀려 가운데로 나왔다. */
.intl-custom-law__table .intl-custom-law__title {
    text-align: start;
}

.intl-custom-law__title a {
    color: #172033;
    font-weight: 600;
    text-decoration: none;
}

.intl-custom-law__title a:hover,
.intl-custom-law__title a:focus-visible {
    color: #2266df;
    text-decoration: underline;
}

.intl-custom-law__notice td {
    background: #f7f9fc;
}

.intl-custom-law__notice em {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 3px 10px;
    border-radius: 999px;
    background: #172033;
    color: #fff;
    font-size: .76rem;
    font-style: normal;
    font-weight: 700;
}

.intl-custom-law__status {
    font-weight: 600;
}

.intl-custom-law__status.is-completed {
    color: #2266df;
}

.intl-custom-law__status.is-processing {
    color: #0f7a5a;
}

.intl-custom-law__status.is-waiting {
    color: #9a5a00;
}

.intl-custom-law__status.is-rejected {
    color: #b3261e;
}

.intl-custom-law__empty {
    padding-block: 56px;
    color: #646e81;
}

/* ③ 하단 : 목록 수 · 페이징 · Request */
.intl-custom-law__foot {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-block-start: 24px;
}

.intl-custom-law__page-size {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #646e81;
    font-size: .9rem;
}
.intl-custom-law__btn-request {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 108px;
    height: 40px;
    padding-inline: 20px;
    border-radius: 8px;
    background: #246beb;
    color: #fff;
    font-weight: 700;
    text-decoration: none;
}

.intl-custom-law__btn-request:hover,
.intl-custom-law__btn-request:focus-visible {
    background: #1a5ad0;
}

/* ── 상세 (UI-A-10-01-02) ───────────────────────────────── */
.intl-custom-detail {
    margin-block-start: 32px;
}

.intl-custom-detail__title {
    margin: 0 0 12px;
    color: #172033;
    font-size: 1.15rem;
}

.intl-custom-detail__table {
    width: 100%;
    border-collapse: collapse;
    border-block-start: 2px solid #172033;
    table-layout: fixed;
}

.intl-custom-detail__table caption {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.intl-custom-detail__table th,
.intl-custom-detail__table td {
    padding: 14px 16px;
    border-block-end: 1px solid #e8edf4;
    color: #172033;
    font-size: .92rem;
    line-height: 1.6;
    text-align: start;
    vertical-align: top;
    word-break: break-word;
}

.intl-custom-detail__table th {
    width: 150px;
    background: #f7f9fc;
    font-weight: 700;
}

/* 답변 HTML 이 표를 넘기지 않도록 가둔다 */
.intl-custom-detail__body {
    overflow-x: auto;
}

.intl-custom-detail__body img,
.intl-custom-detail__body table {
    max-width: 100%;
}

.intl-custom-detail__related,
.intl-custom-detail__files {
    margin: 0;
    padding: 0;
    list-style: none;
}

.intl-custom-detail__related li + li,
.intl-custom-detail__files li + li {
    margin-block-start: 6px;
}

.intl-custom-detail__related-item {
    position: relative;
}

.intl-custom-detail__related a,
.intl-custom-detail__files a {
    color: #2266df;
    text-decoration: underline;
}

.intl-custom-detail__tip {
    display: none;
    position: absolute;
    z-index: 5;
    inset-inline-start: 0;
    top: calc(100% + 4px);
    width: min(420px, calc(100% - 16px));
    padding: 14px 16px;
    border-radius: 12px;
    background: #172033;
    color: #fff;
    box-shadow: 0 8px 24px rgba(23, 32, 51, .2);
}

.intl-custom-detail__tip::before {
    content: "";
    position: absolute;
    inset-inline-start: 24px;
    top: -6px;
    border: 6px solid transparent;
    border-bottom-color: #172033;
    border-top-width: 0;
}

.intl-custom-detail__tip strong {
    display: block;
    margin-block-end: 6px;
    font-size: .9rem;
}

.intl-custom-detail__tip p {
    margin: 0;
    color: #d7dde8;
    font-size: .82rem;
    line-height: 1.45;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.intl-custom-detail__related-item:hover .intl-custom-detail__tip,
.intl-custom-detail__related-item:focus-within .intl-custom-detail__tip {
    display: block;
}

.intl-custom-detail__foot {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-block-start: 24px;
}

.intl-custom-detail__auth {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.intl-custom-detail__auth label {
    color: #172033;
    font-weight: 700;
    font-size: .92rem;
}

.intl-custom-detail__auth input {
    width: 220px;
    height: 44px;
    padding-inline: 14px;
    border: 1px solid #c5cedb;
    border-radius: 8px;
    background: #fff;
    font: inherit;
}

.intl-custom-detail__actions {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-inline-start: auto;
}

.intl-custom-detail__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 92px;
    height: 40px;
    padding-inline: 18px;
    border: 1px solid #c5cedb;
    border-radius: 8px;
    background: #fff;
    color: #172033;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.intl-custom-detail__btn:hover,
.intl-custom-detail__btn:focus-visible {
    border-color: #246beb;
    color: #2266df;
}

/* ── 등록 (UI-A-10-01-03) ───────────────────────────────── */
.intl-custom-form__terms,
.intl-custom-form__fields,
.intl-custom-form__consent {
    margin-block-start: 32px;
}

.intl-custom-form__check {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding-block: 14px;
}

.intl-custom-form__check--all {
    border-block-end: 1px solid #dfe4ec;
}

.intl-custom-form__check input {
    width: 18px;
    height: 18px;
    margin-block-start: 2px;
    flex: 0 0 auto;
}

.intl-custom-form__check label {
    color: #172033;
    font-size: .95rem;
    line-height: 1.5;
    cursor: pointer;
}

.intl-custom-form__grounds thead th {
    background: #f2f5fa;
    text-align: center;
}

.intl-custom-form__required-note {
    margin: 0 0 10px;
    color: #b3261e;
    font-size: .88rem;
}

.intl-custom-form__req {
    margin-inline-start: 4px;
    color: #b3261e;
    text-decoration: none;
}

.intl-custom-form__fields input[type="text"],
.intl-custom-form__fields input[type="email"],
.intl-custom-form__fields input[type="password"],
.intl-custom-form__fields textarea {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #c5cedb;
    border-radius: 8px;
    background: #fff;
    font: inherit;
}

.intl-custom-form__fields input[type="text"],
.intl-custom-form__fields input[type="email"],
.intl-custom-form__fields input[type="password"] {
    height: 44px;
}

.intl-custom-form__fields textarea {
    min-height: 180px;
    resize: vertical;
}

.intl-custom-form__hint {
    display: block;
    margin-block-start: 6px;
    color: #2266df;
    font-size: .85rem;
}

.intl-custom-form__count {
    margin: 6px 0 0;
    color: #646e81;
    font-size: .85rem;
    text-align: end;
}

.intl-custom-form__count .is-over {
    color: #b3261e;
    font-weight: 700;
}

.intl-custom-form__radio {
    display: flex;
    justify-content: center;
    gap: 24px;
    padding-block: 16px;
}

.intl-custom-form__radio label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #172033;
    font-size: .95rem;
    cursor: pointer;
}

.intl-custom-form__retention {
    padding: 18px 20px;
    border: 1px solid #dfe4ec;
    border-radius: 12px;
    background: #f7f9fc;
}

.intl-custom-form__retention h3 {
    margin: 0 0 8px;
    color: #172033;
    font-size: .95rem;
}

.intl-custom-form__retention p {
    margin: 0 0 6px;
    color: #3d4757;
    font-size: .9rem;
    line-height: 1.6;
}

.intl-custom-form__foot {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-block-start: 28px;
}

@media (max-width: 640px) {
    .intl-custom-form__radio {
        justify-content: flex-start;
    }

    .intl-custom-form__foot > * {
        flex: 1 1 auto;
    }
}

@media (max-width: 640px) {
    .intl-custom-detail__table,
    .intl-custom-detail__table tbody,
    .intl-custom-detail__table tr,
    .intl-custom-detail__table th,
    .intl-custom-detail__table td {
        display: block;
        width: auto;
    }

    .intl-custom-detail__table th {
        border-block-end: 0;
    }

    .intl-custom-detail__foot {
        flex-direction: column;
        align-items: stretch;
    }

    .intl-custom-detail__auth {
        flex-wrap: wrap;
    }

    .intl-custom-detail__auth input {
        flex: 1 1 160px;
        width: auto;
    }

    .intl-custom-detail__actions {
        margin-inline-start: 0;
    }

    .intl-custom-detail__btn {
        flex: 1 1 auto;
    }
}

@media (max-width: 640px) {
    .intl-custom-law__result-head {
        flex-direction: column;
        align-items: stretch;
    }

    .intl-custom-law__foot {
        flex-direction: column;
        align-items: stretch;
    }
    .intl-custom-law__btn-request {
        width: 100%;
    }
}

/* a11y: raise specificity so ".intl-page a { color: inherit }" does not override white text (contrast 4.8:1) */
.intl-page a.intl-custom-law__btn-request { color: #fff; }
