/* KY の足りない所の直し (2026-11-10)。ky-improve.js が足す部品の見た目。今の画面の色 (style.css) に合わせる */

.kyi-toast {
    position: fixed;
    left: 50%;
    transform: translateX(-50%);
    top: calc(12px + env(safe-area-inset-top, 0px));
    z-index: 100002;
    max-width: min(560px, calc(100vw - 24px));
    display: flex;
    gap: 10px;
    align-items: center;
    padding: 12px 14px;
    border-radius: 10px;
    background: #fff4f2;
    border: 1px solid #e0a39a;
    color: #7a1f12;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.18);
    font-size: 14px;
    line-height: 1.5;
}
.kyi-toast[hidden] { display: none; }
.kyi-toast-ok { background: #eef8f0; border-color: #9ccfa8; color: #1d5b2c; }
.kyi-toast-text { flex: 1; min-width: 0; }
.kyi-toast-btn {
    flex: none;
    padding: 6px 12px;
    border-radius: 6px;
    border: 1px solid currentColor;
    background: #fff;
    color: inherit;
    font-weight: 700;
    cursor: pointer;
}
.kyi-toast-close {
    flex: none;
    border: none;
    background: transparent;
    color: inherit;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    padding: 2px 4px;
}

.kyi-hint { margin: 6px 0 0; font-size: 12px; color: #5b6b70; line-height: 1.5; }
.kyi-hint[hidden] { display: none; }

/* 作った画面の「承認依頼を出す」 */
.kyi-submit-box {
    margin: 12px 0 16px;
    padding: 14px 16px;
    border: 2px solid #2b6cb0;
    border-radius: 10px;
    background: #f1f6fc;
}
.kyi-submit-head { font-weight: 700; font-size: 16px; color: #1f4f86; margin-bottom: 4px; }
.kyi-submit-text { font-size: 13px; color: #34495e; line-height: 1.6; margin-bottom: 10px; }
.kyi-submit-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.kyi-submit-row .btn-large { min-height: 48px; }
.kyi-submit-row [hidden] { display: none; }

/* 差し戻し */
.status-badge.status-returned, .kyi-badge-returned { background: #c0392b !important; color: #fff; }
.kyi-returned-banner {
    margin: 0 0 16px;
    padding: 12px 16px;
    border-left: 5px solid #c0392b;
    border-radius: 8px;
    background: #fdecea;
    color: #6b1d14;
    line-height: 1.6;
}
.kyi-returned-head { font-weight: 700; font-size: 16px; }
.kyi-returned-time { font-weight: 400; font-size: 12px; color: #8a4a42; margin-left: 6px; }
.kyi-returned-reason { margin-top: 4px; white-space: pre-wrap; word-break: break-word; }
.kyi-returned-next { margin-top: 6px; font-size: 13px; }
.kyi-list-returned { margin-top: 2px; font-size: 12px; color: #a93226; word-break: break-word; }
.kyi-list-people { color: #5b6b70; }

/* 一覧の道具 (自分が担当・並び) */
.kyi-list-tools { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; margin: -4px 0 12px; }
.kyi-list-tools [hidden] { display: none; }
.kyi-list-sort-label { display: inline-flex; gap: 6px; align-items: center; font-size: 13px; color: #34495e; }
.kyi-list-sort-label select { padding: 6px 8px; border: 1px solid #ccc; border-radius: 6px; font-size: 13px; max-width: 100%; }
.kyi-card-link { cursor: pointer; }
.kyi-card-link:hover, .kyi-card-link:focus-visible { box-shadow: 0 0 0 2px #2b6cb0 inset; outline: none; }
button.kyi-activity {
    display: block;
    width: 100%;
    text-align: left;
    background: transparent;
    border: none;
    border-bottom: 1px solid #eee;
    font: inherit;
    color: inherit;
    cursor: pointer;
    padding: 6px 0;
}
button.kyi-activity:hover, button.kyi-activity:focus-visible { background: #f4f8fc; outline: none; }
.kyi-activity-ky { color: #1f4f86; font-weight: 600; }

/* 現場管理: 止めた現場 */
.kyi-suspended { margin-top: 20px; }
.kyi-suspended > summary { cursor: pointer; color: #34495e; font-weight: 600; padding: 6px 0; }
.kyi-suspended-item { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.kyi-error-line { color: #a93226; }

/* アカウント管理: 探す */
.kyi-account-search { display: flex; flex-direction: column; gap: 4px; margin-bottom: 12px; }
.kyi-account-search label { font-size: 13px; color: #34495e; }
.kyi-account-search input { padding: 8px 12px; border: 1px solid #ccc; border-radius: 6px; font-size: 15px; max-width: 420px; }
.company-card[hidden], .company-members > div[hidden] { display: none !important; }

.info-row[hidden], #ky-project-group[hidden] { display: none; }
