﻿:root {
      --bg: #ffffff;
      --text: #111827;
      --muted: #4b5563;
      --line: #cbd5e1;
      --panel: #f8fafc;
      --brand: #14532d;
      --brand-2: #0f766e;
      --accent: #b91c1c;
      --blue: #1d4ed8;
      --purple: #6d28d9;
      --yellow: #854d0e;
      --green-bg: #dcfce7;
      --purple-bg: #ede9fe;
      --yellow-bg: #fef3c7;
      --gray-bg: #e5e7eb;
      --blue-bg: #dbeafe;
      --red-bg: #fee2e2;
      --focus: #f59e0b;
      font-family: "Yu Gothic", "Meiryo", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
    }

    * { box-sizing: border-box; }

    body {
      margin: 0;
      min-height: 100vh;
      background: var(--bg);
      color: var(--text);
      font-size: 18px;
      line-height: 1.65;
    }

    button, input, select, textarea {
      font: inherit;
    }

    button, .button-link {
      min-height: 56px;
      border: 2px solid transparent;
      border-radius: 8px;
      padding: 12px 18px;
      font-size: 20px;
      font-weight: 700;
      cursor: pointer;
      background: var(--brand);
      color: #fff;
      text-decoration: none;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      gap: 8px;
      touch-action: manipulation;
    }

    button.secondary { background: #fff; color: var(--brand); border-color: var(--brand); }
    button.warning { background: var(--accent); }
    button.neutral { background: #374151; }
    button:disabled { background: #9ca3af; color: #111827; cursor: not-allowed; border-color: #6b7280; }

    a { color: #0645ad; font-weight: 700; }

    input, select, textarea {
      width: 100%;
      min-height: 54px;
      border: 2px solid #64748b;
      border-radius: 8px;
      padding: 10px 12px;
      background: #fff;
      color: var(--text);
      font-size: 18px;
    }

    textarea { min-height: 110px; resize: vertical; }
    label { display: block; font-weight: 700; margin-bottom: 6px; }
    :focus-visible { outline: 4px solid var(--focus); outline-offset: 3px; }

    .app {
      width: min(1120px, 100%);
      margin: 0 auto;
      padding: 18px;
    }

    .screen { display: none; }
    .screen.active { display: block; }

    .top-title {
      margin: 14px 0 18px;
      font-size: clamp(30px, 7vw, 48px);
      line-height: 1.2;
      color: var(--brand);
      letter-spacing: 0;
    }

    .sub-title {
      margin: 0 0 20px;
      font-size: 22px;
      color: var(--muted);
      font-weight: 700;
    }

    .panel {
      border: 2px solid var(--line);
      border-radius: 8px;
      padding: 18px;
      background: var(--panel);
      margin-bottom: 18px;
    }

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

    .full { grid-column: 1 / -1; }

    .actions {
      display: flex;
      gap: 14px;
      flex-wrap: wrap;
      margin-top: 18px;
    }

    .message {
      display: none;
      margin: 16px 0;
      padding: 14px 16px;
      border-radius: 8px;
      border: 2px solid #14532d;
      background: #ecfdf5;
      color: #064e3b;
      font-size: 20px;
      font-weight: 800;
    }

    .message.show { display: block; }
    .message.error { border-color: #b91c1c; background: #fff1f2; color: #991b1b; }

    .demo-info {
      display: grid;
      gap: 10px;
      font-size: 18px;
    }

    .header {
      display: flex;
      justify-content: space-between;
      align-items: flex-start;
      gap: 16px;
      border-bottom: 3px solid var(--brand);
      padding-bottom: 14px;
      margin-bottom: 18px;
    }

    .header h1 {
      margin: 0;
      font-size: clamp(28px, 6vw, 42px);
      color: var(--brand);
      line-height: 1.2;
    }

    .user-line { font-weight: 800; color: var(--text); }

    .month-bar {
      display: grid;
      grid-template-columns: auto 1fr auto auto;
      gap: 10px;
      align-items: center;
      margin-bottom: 14px;
    }

    .month-label {
      text-align: center;
      font-size: 28px;
      font-weight: 900;
    }

    .calendar {
      border: 2px solid var(--line);
      border-radius: 8px;
      overflow: hidden;
      background: #fff;
    }

    .weekdays, .calendar-grid {
      display: grid;
      grid-template-columns: repeat(7, minmax(0, 1fr));
    }

    .weekday {
      padding: 10px 6px;
      text-align: center;
      font-weight: 900;
      background: #f1f5f9;
      border-right: 1px solid var(--line);
      border-bottom: 2px solid var(--line);
    }

    .weekday:last-child { border-right: 0; }

    .day-cell {
      min-height: 138px;
      border-right: 1px solid var(--line);
      border-bottom: 1px solid var(--line);
      padding: 8px;
      background: #fff;
    }

    .day-cell:nth-child(7n) { border-right: 0; }
    .day-cell.blank { background: #f8fafc; }

    .day-button {
      width: 100%;
      height: 100%;
      min-height: 120px;
      display: flex;
      flex-direction: column;
      align-items: flex-start;
      justify-content: flex-start;
      gap: 5px;
      border: 2px solid transparent;
      background: #fff;
      color: var(--text);
      padding: 8px;
      border-radius: 6px;
      text-align: left;
      font-size: 18px;
    }

    .day-button:hover { border-color: var(--brand-2); }
    .day-button.confirmed-viewable {
      background: #fffbeb;
      color: var(--text);
      border: 3px solid #b45309;
      cursor: pointer;
      opacity: 1;
    }

    .day-button.confirmed-viewable:hover,
    .day-button.confirmed-viewable:focus-visible {
      background: #fef3c7;
      border-color: #92400e;
      box-shadow: 0 0 0 4px rgba(245, 158, 11, .32);
    }
    .date-num { font-size: 24px; font-weight: 900; }
    .sunday, .holiday { color: #b91c1c; }
    .saturday { color: #1d4ed8; }
    .past .date-num { color: #6b7280; }

    .status-chip {
      display: inline-flex;
      align-items: center;
      min-height: 30px;
      padding: 3px 8px;
      border-radius: 6px;
      font-weight: 900;
      font-size: 16px;
      color: #111827;
      border: 1px solid rgba(0,0,0,.18);
    }

    .status-none { background: #fff; }
    .status-day { background: var(--green-bg); }
    .status-night { background: var(--purple-bg); }
    .status-both { background: linear-gradient(180deg, var(--green-bg) 0 50%, var(--purple-bg) 50%); }
    .status-unavailable { background: var(--red-bg); }
    .status-locked { background: var(--gray-bg); }

    .legend {
      display: flex;
      flex-wrap: wrap;
      gap: 10px;
      margin: 16px 0;
    }

    .modal-backdrop {
      position: fixed;
      inset: 0;
      display: none;
      align-items: center;
      justify-content: center;
      background: rgba(17, 24, 39, .72);
      z-index: 1500;
      padding: 16px;
    }

    .modal-backdrop.show { display: flex; }

    .modal {
      width: min(720px, 100%);
      max-height: 92vh;
      overflow: auto;
      background: #fff;
      border-radius: 8px;
      padding: 20px;
      border: 3px solid var(--brand);
      box-shadow: 0 24px 80px rgba(0,0,0,.35);
    }

    .modal h2 {
      margin: 0 0 14px;
      font-size: 30px;
      line-height: 1.25;
    }

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

    .choice {
      min-height: 76px;
      background: #fff;
      color: var(--text);
      border: 3px solid #64748b;
      justify-content: flex-start;
      text-align: left;
      transition: background-color .15s ease, border-color .15s ease, box-shadow .15s ease, transform .15s ease;
    }

    .choice[aria-pressed="true"] {
      color: #fff;
      border-color: #f59e0b;
      outline: 3px solid #111827;
      outline-offset: 2px;
      box-shadow: 0 0 0 6px rgba(245, 158, 11, .32), 0 6px 14px rgba(17, 24, 39, .22);
      transform: translateY(-2px);
    }

    .choice[aria-pressed="true"]::before {
      content: "✓ 選択中　";
      font-weight: 900;
    }

    .choice.day { background: var(--green-bg); }
    .choice.night { background: var(--purple-bg); }
    .choice.unavailable { background: var(--red-bg); }
    .choice.both { background: linear-gradient(135deg, var(--green-bg) 0 50%, var(--purple-bg) 50% 100%); }
    .choice.day[aria-pressed="true"] { background: #166534; }
    .choice.night[aria-pressed="true"] { background: #5b21b6; }
    .choice.unavailable[aria-pressed="true"] { background: #b91c1c; }
    .choice.both[aria-pressed="true"] { background: linear-gradient(135deg, #166534 0 50%, #5b21b6 50% 100%); }

    .lock-note {
      padding: 12px;
      background: #fef3c7;
      border: 2px solid #b45309;
      border-radius: 8px;
      font-weight: 800;
      margin: 12px 0;
    }

    .admin-tools {
      display: grid;
      grid-template-columns:minmax(185px,220px) minmax(220px,1fr) auto auto;
      gap:10px;
      align-items: end;
    }

    #adminScreen .admin-control-panel {
      position:relative;
      z-index:1;
      isolation:isolate;
      overflow:visible;
      padding:14px 16px;
      opacity:1;
      transform:none;
      filter:none;
      contain:none;
      will-change:auto;
      animation:none;
      transition:none;
    }
    #adminScreen .admin-control-panel::before,
    #adminScreen .admin-control-panel::after { display:none; content:none; }
    #adminScreen .admin-tools input { min-height:44px; }
    #adminScreen .admin-tools button,
    #adminScreen .filter-buttons button,
    #adminScreen .integrated-management-actions button { min-height:44px; padding:8px 14px; font-size:16px; }
    #adminScreen .integrated-management-actions { display:flex; gap:10px; margin-bottom:10px; }
    #adminScreen .integrated-management-actions .wide-action { flex:0 1 auto; width:auto; }
    #adminScreen .integrated-management-actions .small-text { flex:1 1 320px; align-self:center; }

    .filter-buttons {
      display: flex;
      gap: 10px;
      flex-wrap: wrap;
      margin: 14px 0;
    }

    .filter-buttons button {
      background: #fff;
      color: var(--text);
      border-color: #64748b;
    }

    .filter-buttons button.active {
      background: var(--brand);
      color: #fff;
      border-color: var(--brand);
    }

    table {
      width: 100%;
      border-collapse: collapse;
      background: #fff;
      font-size: 18px;
    }

    th, td {
      border: 1px solid var(--line);
      padding: 10px;
      text-align: left;
      vertical-align: top;
    }

    th {
      background: #f1f5f9;
      font-weight: 900;
    }

    .admin-cards { display: none; }
    .monthly-schedule-scroll {
      position:relative;
      z-index:0;
      isolation:isolate;
      width:100%;
      max-height:calc(100vh - 230px);
      overflow-x:auto;
      overflow-y:auto;
      border:2px solid #64748b;
      border-radius:8px;
      box-sizing:border-box;
      background:#fff;
      overscroll-behavior:contain;
      scrollbar-gutter:stable;
    }
    .registration-branch-result {
      display:flex;
      flex-direction:column;
      justify-content:center;
      min-height:72px;
      padding:10px 14px;
      border:2px solid #166534;
      border-radius:8px;
      background:#f0fdf4;
      color:#166534;
    }
    .registration-branch-result span { color:#334155; font-size:15px; }

    #adminScreen .filter-buttons { margin:10px 0 8px; }
    .kana-page-buttons {
      display:flex;
      gap:4px;
      overflow-x:visible;
      overflow-y:visible;
      padding:4px 0 2px;
      scrollbar-width:thin;
    }
    .kana-page-buttons button {
      flex:1 0 62px;
      box-sizing:border-box;
      height:40px;
      min-height:40px;
      padding:6px 9px;
      border:2px solid transparent;
      background:#fff;
      color:#334155;
      font-size:15px;
      font-weight:700;
      white-space:nowrap;
    }
    .kana-page-buttons button:hover { color:#166534; background:#f0fdf4; }
    .kana-page-buttons button.active {
      color:#166534;
      border-color:#166534;
      background:#f0fdf4;
    }
    #adminScreen .monthly-schedule-table {
      width:max-content;
      min-width:100%;
      table-layout:fixed;
      border-collapse:separate;
      border-spacing:0;
      margin:0;
      font-size:15px;
    }
    .monthly-schedule-table th,
    .monthly-schedule-table td {
      min-width:48px;
      height:34px;
      padding:3px 4px;
      border:0;
      border-right:1px solid #94a3b8;
      border-bottom:1px solid #94a3b8;
      text-align:center;
      vertical-align:middle;
    }
    .monthly-schedule-table thead th {
      position:sticky;
      top:0;
      z-index:20;
      height:52px;
      background:#e2e8f0;
      line-height:1.25;
      white-space:nowrap;
    }
    .monthly-schedule-table .schedule-name-head,
    .monthly-schedule-table .schedule-name-cell {
      position:sticky;
      left:0 !important;
      z-index:15;
      width:190px;
      min-width:190px;
      max-width:190px;
      background:#fff;
      text-align:left;
      border-right:2px solid #111827;
    }
    .monthly-schedule-table .schedule-name-head { z-index:30; background:#dbeafe; text-align:center; }
    .monthly-schedule-table .schedule-name-cell.menu-open { z-index:120; }
    .monthly-schedule-table .schedule-shift-head,
    .monthly-schedule-table .schedule-shift-label { min-width:52px; width:52px; background:#f8fafc; font-weight:900; }
    .monthly-schedule-table tbody tr:nth-child(even) > .schedule-shift-label,
    .monthly-schedule-table tbody tr:nth-child(even) > .schedule-mark,
    .monthly-schedule-table .schedule-name-cell { border-bottom:2px solid #111827; }
    .schedule-person { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:4px; align-items:center; }
    .schedule-person .worker-action-menu-wrap { width:auto; }
    .schedule-person-number { display:block; color:#475569; font-size:12px; font-weight:800; }
    .schedule-person-name { display:block; overflow:hidden; font-size:15px; font-weight:900; text-overflow:ellipsis; white-space:nowrap; }
    .schedule-person .worker-action-menu-button { width:34px !important; min-width:34px; min-height:34px; font-size:22px; }
    .schedule-mark { font-size:23px; font-weight:900; line-height:1; }
    .schedule-mark.is-available { color:#15803d; background:#f0fdf4; }
    .schedule-mark.is-unavailable { color:#b91c1c; background:#fff1f2; }
    .schedule-mark.is-past-blank { color:#475569; background:#e5e7eb; }
    .monthly-schedule-table .is-proxy-editable-range.is-day { border-top:3px solid #f59e0b; }
    .monthly-schedule-table .is-proxy-editable-range.is-night { border-bottom:3px solid #f59e0b; }
    .monthly-schedule-table tr.is-proxy-target > .is-proxy-editable-range:last-child { border-right:3px solid #f59e0b; }
    .monthly-schedule-table .schedule-name-cell.is-proxy-target-name {
      border-top:3px solid #f59e0b;
      border-bottom:3px solid #f59e0b;
      border-left:3px solid #f59e0b;
      background:#fef3c7;
    }
    .proxy-active-label { display:inline-block; margin-top:5px; padding:3px 7px; border-radius:999px; background:#b45309; color:#fff; font-size:12px; font-weight:900; }
    .schedule-mark.is-proxy-editable { cursor:pointer; }
    .schedule-mark.is-proxy-editable:hover { background-color:#fffbeb; }
    .schedule-mark.is-saving { cursor:pointer; opacity:.7; }
    .proxy-complete-button {
      width:36px !important;
      min-width:36px;
      min-height:36px;
      padding:0;
      border-radius:10px;
      background:#166534;
      color:#fff;
      font-size:23px;
      line-height:1;
    }
    .proxy-complete-button:disabled { cursor:default; opacity:.6; }
    .schedule-day-header.is-sunday { color:#b91c1c; background:#fee2e2; }
    .schedule-day-header.is-saturday { color:#1d4ed8; background:#dbeafe; }
    .monthly-schedule-table .schedule-day-header[role="button"] { cursor:pointer; }
    .monthly-schedule-table .schedule-day-header[role="button"]:focus-visible { outline:4px solid #111827; outline-offset:-4px; }
    .monthly-schedule-table .schedule-day-header.is-selected-date {
      color:#0f172a;
      background:#bfdbfe;
      border-top:3px solid #1d4ed8;
      border-right:3px solid #1d4ed8;
      border-left:3px solid #1d4ed8;
    }
    .monthly-schedule-table .schedule-day-header.is-selected-date::after {
      content:"選択中";
      display:block;
      margin-top:2px;
      color:#1d4ed8;
      font-size:10px;
      font-weight:900;
    }
    .monthly-schedule-table .schedule-mark.is-selected-date {
      border-right:3px solid #2563eb;
      border-left:3px solid #2563eb;
      background-image:linear-gradient(rgba(219,234,254,.45),rgba(219,234,254,.45));
    }
    #adminScreen .admin-cards { display:none !important; }
    .admin-table-bottom-space { min-height:clamp(420px,58vh,640px); background:#fff; }
    body.admin-screen-active .app { width:min(1500px,100%); }
    #menuShiftBuilderButton { display:none !important; }
    .role-badge {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      min-height: 34px;
      margin-left: 10px;
      padding: 4px 10px;
      border: 2px solid currentColor;
      border-radius: 999px;
      font-size: 16px;
      line-height: 1.2;
      font-weight: 900;
      white-space: nowrap;
    }
    .desktop-table { overflow-x: auto; }
    .admin-summary-row td { vertical-align: middle; line-height: 1.45; }
    .admin-summary-line { margin: 3px 0; overflow-wrap: anywhere; }
    .admin-summary-number, .admin-summary-status, .admin-summary-name { font-weight: 900; }
    .admin-summary-row td:nth-child(3) .admin-summary-line:first-child {
      display: -webkit-box;
      overflow: hidden;
      -webkit-box-orient: vertical;
      -webkit-line-clamp: 2;
    }
    .admin-summary-row td:last-child button { width: 100%; min-width: 100px; }
    .role-badge-guard { color: #1e40af; background: #eff6ff; }
    .role-badge-staff { color: #166534; background: #f0fdf4; }
    .role-badge-admin { color: #9f1239; background: #fff1f2; }
    .role-badge-unknown { color: #475569; background: #f8fafc; }
    .admin-card-heading {
      display: flex;
      align-items: center;
      flex-wrap: wrap;
      gap: 4px;
      margin-bottom: 8px;
      font-size: 21px;
      font-weight: 900;
    }
    .admin-card-details {
      font-size: 18px;
      line-height: 1.65;
      white-space: pre-line;
    }
    .small-text { font-size: 16px; color: var(--muted); font-weight: 700; }
    .bold { font-weight: 900; }

    .toast {
      position: fixed;
      left: 50%;
      bottom: 18px;
      transform: translateX(-50%);
      width: min(560px, calc(100% - 28px));
      display: none;
      padding: 14px 18px;
      border: 3px solid var(--brand);
      border-radius: 8px;
      background: #ecfdf5;
      color: #064e3b;
      font-size: 22px;
      font-weight: 900;
      text-align: center;
      z-index: 30;
    }

    .toast.show { display: block; }

    @media (max-width: 760px) {
      .app { padding: 12px; }
      #calendarScreen {
        padding-bottom: calc(30vh + env(safe-area-inset-bottom, 0px));
      }
      @supports (height: 100svh) {
        #calendarScreen {
          padding-bottom: calc(30svh + env(safe-area-inset-bottom, 0px));
        }
      }
      .form-grid, .admin-tools, .choice-grid { grid-template-columns: 1fr; }
      .header {
        position: relative;
        display: block;
        min-height: 60px;
        padding-right: 72px;
      }
      .header .actions { margin-top: 12px; }
      .header .menu-button {
        position: absolute;
        top: 0;
        right: 0;
        width: 60px !important;
        min-width: 60px;
        max-width: 60px;
        height: 60px;
        min-height: 60px;
        padding: 0;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border-radius: 10px;
        line-height: 1;
        margin: 0;
      }
      .header .menu-button.has-notification-badge {
        position: absolute;
        top: 0;
        right: 0;
      }
      .header .menu-button[hidden] { display: none; }
      .month-bar {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        grid-template-areas:
          "label label label"
          "previous current next";
      }
      .month-label { grid-area: label; text-align: center; }
      #prevMonthButton { grid-area: previous; }
      #todayButton { grid-area: current; }
      #nextMonthButton { grid-area: next; }
      .month-bar button { min-width: 0; padding-inline: 8px; white-space: nowrap; }
      .weekdays { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
      .weekday { padding: 7px 1px; font-size: 15px; }
      .calendar-grid { grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 0; padding: 0; background: #fff; }
      .day-cell {
        min-height: 92px;
        border-right: 1px solid #94a3b8;
        border-bottom: 1px solid #94a3b8;
        border-radius: 0;
        padding: 0;
      }
      .day-cell.blank { display: block; }
      .day-button { min-height: 90px; padding: 4px 2px; gap: 3px; border-radius: 0; overflow: hidden; }
      .date-number { font-size: 21px; line-height: 1.1; font-weight: 900; }
      .holiday-name { max-width: 100%; font-size: 9px; line-height: 1.1; overflow-wrap: anywhere; }
      .status-chip { max-width: 100%; min-height: 23px; padding: 1px 3px; font-size: 11px; line-height: 1.25; white-space: nowrap; }
      .deadline-mini { font-size: 10px; line-height: 1.2; font-weight: 900; }
      .calendar { width: 100%; overflow: hidden; border: 2px solid #94a3b8; background: #fff; }
      .desktop-table { display: none; }
      .admin-cards { display: grid; gap: 12px; }
      .admin-card {
        border: 2px solid var(--line);
        border-radius: 8px;
        padding: 14px;
        background: #fff;
      }
      .role-badge { min-height: 36px; font-size: 17px; }
      button, .button-link { width: 100%; }
      .actions, .filter-buttons { flex-direction: column; }
    }
/* メール確認画面でも高齢者向けの読みやすさを維持する */
.large-help {
  font-size: 1.18rem;
  line-height: 1.8;
  font-weight: 700;
}
.checkbox-label { display:flex; align-items:center; gap:12px; font-size:1.15rem; font-weight:700; }
.checkbox-label input { width:28px; height:28px; }
.staff-request-option { margin-top:20px; padding:18px; border:2px solid var(--line); border-radius:12px; }
.menu-button { min-width:64px; font-size:2rem; padding:8px 18px; }
.menu-button.has-notification-badge { position:relative; overflow:visible; }
.application-notification-badge {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:25px;
  height:25px;
  padding:0 6px;
  border:2px solid #fff;
  border-radius:999px;
  background:#c81e1e;
  color:#fff;
  font-size:14px;
  font-weight:900;
  line-height:1;
  box-sizing:border-box;
  pointer-events:none;
}
.application-notification-badge[hidden] { display:none; }
.menu-button > .application-notification-badge {
  position:absolute;
  top:-8px;
  right:-8px;
  z-index:2;
}
.side-menu button.has-notification-badge {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}
.side-menu button > .application-notification-badge { flex:0 0 auto; }
.side-menu-backdrop { position:fixed; inset:0; background:rgba(15,23,42,.45); display:none; z-index:1000; }
.side-menu-backdrop.show { display:block; }
body.side-menu-open { overflow:hidden; }
.side-menu {
  position:absolute;
  right:0;
  top:0;
  width:min(86vw,380px);
  height:100vh;
  height:100dvh;
  max-height:100vh;
  max-height:100dvh;
  overflow-y:auto;
  overscroll-behavior:contain;
  -webkit-overflow-scrolling:touch;
  background:#fff;
  padding:calc(24px + env(safe-area-inset-top)) calc(24px + env(safe-area-inset-right)) calc(24px + env(safe-area-inset-bottom)) 24px;
  display:flex;
  flex-direction:column;
  gap:16px;
  box-shadow:-8px 0 24px rgba(0,0,0,.2);
  box-sizing:border-box;
}
.side-menu-group { display:grid; gap:10px; border-top:2px solid #cbd5e1; padding-top:14px; }
.side-menu-group > strong { font-size:20px; color:#163c27; }
.side-menu-select { display:grid; gap:8px; font-size:20px; font-weight:800; }
.side-menu-select select { min-height:54px; font-size:20px; }
.pending-approval-panel { max-width:760px; margin:40px auto; text-align:center; font-size:24px; }
.pending-approval-message { white-space:pre-line; line-height:1.8; }
.pending-approval-panel button { width:min(360px,100%); min-height:58px; margin-top:18px; }
.single-column-form { grid-template-columns:1fr; }
.compact-option { margin:14px 0; padding:14px 18px; }
.shift-branch-selector { margin:0 0 20px; padding:18px; border:3px solid var(--brand); border-radius:12px; background:#f0fdf4; }
.shift-branch-selector label { display:block; margin-bottom:8px; font-size:22px; font-weight:900; }
.shift-branch-selector select { width:100%; min-height:58px; font-size:21px; }
.account-approval-card { white-space:pre-line; display:grid; gap:14px; }
.account-approval-card select { width:100%; margin-top:8px; }
.mobile-only-list { display:none; }
.side-menu button { width:100%; min-height:58px; font-size:1.1rem; }
.request-list { display:grid; gap:16px; }
.request-card { background:#fff; border:2px solid var(--line); border-radius:14px; padding:20px; font-size:1.08rem; line-height:1.7; }
.request-actions { display:flex; flex-wrap:wrap; gap:12px; margin-top:14px; }
[hidden] { display: none !important; }
.shift-toolbar { display:flex; flex-wrap:wrap; gap:12px; align-items:end; }
.shift-toolbar label { min-width:220px; }
.shift-toolbar button.active { background:var(--brand); color:#fff; }
.shift-groups { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:14px; margin:18px 0; align-items:start; }
.shift-group-card { min-width:0; border:2px solid var(--line); border-radius:12px; padding:14px; background:#fff; font-size:17px; line-height:1.55; overflow-wrap:anywhere; }
.shift-group-card h2 { margin:0 0 8px; font-size:24px; line-height:1.3; }
.shift-group-card .group-card-title {
  display:block;
  width:100%;
  color:#111827;
  font-weight:900;
  overflow-wrap:anywhere;
  word-break:normal;
}
.status-label { display:inline-block; padding:3px 10px; border-radius:999px; background:#dbeafe; font-weight:900; }
.group-card-heading { display:flex; align-items:flex-start; justify-content:flex-end; gap:12px; margin-bottom:8px; }
.group-card-controls { display:flex; align-items:flex-start; justify-content:flex-end; flex-wrap:wrap; gap:8px; flex:0 0 auto; }
.shift-status-badge {
  display:inline-flex;
  min-height:42px;
  align-items:center;
  padding:6px 14px;
  border:3px solid;
  border-radius:999px;
  font-size:18px;
  font-weight:900;
  white-space:nowrap;
}
.shift-status-badge.is-draft { color:#1e3a8a; background:#eff6ff; border-color:#2563eb; }
.shift-status-badge.is-confirmed { color:#78350f; background:#fef3c7; border-color:#b45309; }
.shift-card-audit { color:#374151; font-size:16px; }
.audit-meta { color:#6b7280; font-size:14px; line-height:1.55; white-space:pre-line; }
.shift-group-card.status-draft-card { box-shadow:inset 0 7px 0 #2563eb; }
.shift-group-card.status-confirmed-card { box-shadow:inset 0 7px 0 #b45309; background:#fffdf5; }
.shift-card-menu-wrap { position:relative; }
.shift-card-menu-button {
  width:52px !important;
  min-width:52px;
  min-height:52px;
  padding:0;
  border-radius:10px;
  font-size:32px;
  line-height:1;
}
.shift-card-menu {
  position:absolute;
  top:calc(100% + 6px);
  right:0;
  z-index:80;
  width:min(290px,calc(100vw - 36px));
  padding:8px;
  display:grid;
  gap:7px;
  border:3px solid var(--brand);
  border-radius:12px;
  background:#fff;
  box-shadow:0 14px 34px rgba(15,23,42,.28);
}
.shift-card-menu button { width:100%; min-height:54px; padding:10px 14px; font-size:18px; text-align:left; }
.shift-card-menu .menu-delete { color:#fff; background:#b91c1c; border-color:#b91c1c; }
.shift-group-card.menu-open { position:relative; z-index:20; }
.duplicated-shift-notice {
  margin-top:10px;
  padding:10px;
  border:2px solid #b45309;
  border-radius:8px;
  background:#fffbeb;
  color:#78350f;
  font-size:16px;
  font-weight:900;
}
.completion-badge { display:inline-flex; min-height:42px; align-items:center; padding:6px 14px; border:2px solid; border-radius:999px; font-size:18px; font-weight:900; white-space:nowrap; }
.completion-badge.is-incomplete { color:#991b1b; background:#fff1f2; border-color:#b91c1c; }
.completion-badge.is-complete { color:#14532d; background:#ecfdf5; border-color:#15803d; }
.shift-group-card.incomplete { border:3px solid #b91c1c; }
.incomplete-summary, .completion-warning { margin-top:12px; padding:11px; border:2px solid #b91c1c; border-radius:8px; background:#fff1f2; color:#7f1d1d; font-size:16px; font-weight:800; }
.incomplete-summary ul { margin:6px 0; padding-left:22px; }
.completion-warning.complete { border-color:#15803d; background:#ecfdf5; color:#14532d; }
.input-incomplete { border:3px solid #b91c1c !important; background:#fff7f7; }
.wide-action { width:100%; min-height:72px; font-size:24px; }
.shift-editor { width:min(900px,100%); }
.shift-editor-header { display:flex; align-items:flex-start; justify-content:space-between; gap:18px; margin-bottom:14px; }
.shift-editor-top-actions { display:flex; justify-content:flex-end; flex-wrap:wrap; gap:10px; }
.shift-editor-top-actions button { min-height:52px; font-size:17px; }
.shift-editor h3 { font-size:24px; margin:22px 0 8px; }
.member-search-row { display:grid; grid-template-columns:minmax(0,1fr) 64px; align-items:stretch; }
.member-search-row input { border-radius:8px 0 0 8px; }
.member-candidates-toggle {
  width:64px !important;
  min-width:64px;
  min-height:56px;
  padding:0;
  border-radius:0 8px 8px 0;
  font-size:26px;
  line-height:1;
}
.candidate-list { display:grid; gap:8px; max-height:260px; overflow:auto; padding:10px; border:2px solid var(--line); border-radius:8px; margin:8px 0; }
.candidate-row { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:12px; border:1px solid var(--line); border-radius:8px; font-size:18px; font-weight:700; }
.candidate-main { display:flex; align-items:center; gap:12px; flex:1; margin:0; }
.candidate-row input { width:26px; height:26px; flex:0 0 auto; }
.availability-note-preview { width:auto; min-height:44px; padding:7px 10px; font-size:16px; text-align:left; }
.candidate-no-note { color:var(--muted); font-size:15px; white-space:nowrap; }
.member-section-heading { display:flex; align-items:center; justify-content:space-between; gap:18px; margin-top:22px; }
.member-section-heading h3 { margin:0; }
.member-section-heading .checkbox-label { margin:0; }
.selected-members { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; padding:12px; border:2px solid var(--line); border-radius:8px; }
.selected-member-row { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:10px; border:1px solid var(--line); border-radius:8px; font-size:18px; font-weight:800; }
.member-remove { min-height:48px; font-size:17px; }
.leader-choices { display:flex; flex-wrap:wrap; gap:12px; margin:10px 0; }
.leader-choice { min-height:60px; }
.leader-choice.selected { background:var(--brand); color:#fff; border:4px solid #f59e0b; }
.time-select-row { display:grid; grid-template-columns:minmax(90px,1fr) auto minmax(90px,1fr) auto; align-items:center; gap:8px; }
.time-select-row select { cursor:pointer; }
.number-picker-wrap { position:relative; display:block; }
.number-picker-wrap input { padding-right:64px; }
.number-picker-button { position:absolute; top:0; right:0; width:58px !important; min-width:58px; min-height:54px; padding:0; border-radius:0 8px 8px 0; }
.number-picker-options { position:absolute; top:calc(100% + 6px); right:0; z-index:50; width:min(300px,90vw); padding:10px; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; border:2px solid var(--brand); border-radius:10px; background:#fff; box-shadow:0 12px 32px rgba(0,0,0,.24); }
.number-option { min-height:48px; font-size:18px; }
button.danger { background:#b91c1c; border-color:#b91c1c; }
.status-confirmed { background:#fef3c7; border:2px solid #b45309; }
.confirmed-shift-details { white-space:pre-line; padding:16px; border:3px solid #b45309; border-radius:10px; background:#fffbeb; font-size:19px; font-weight:800; line-height:1.7; }
#shiftTypeDay { margin-left:auto; }
.note-panel-backdrop { position:fixed; inset:0; display:none; align-items:center; justify-content:center; padding:18px; background:rgba(15,23,42,.55); z-index:1200; }
.note-panel-backdrop.show { display:flex; }
.availability-note-panel { position:relative; width:min(720px,100%); max-height:55vh; overflow:auto; padding:22px 64px 22px 22px; border:3px solid var(--brand); border-radius:12px; background:#fff; font-size:18px; line-height:1.7; overflow-wrap:anywhere; }
.availability-note-panel h2 { margin:0 0 12px; font-size:25px; }
.note-panel-close { position:absolute; top:8px; right:8px; width:48px !important; min-width:48px; min-height:48px; padding:0; font-size:30px; line-height:1; }
.compact-action-modal { width:min(560px,100%); }
.compact-action-modal h2 { margin-top:0; }
.operation-confirm-message { white-space:pre-line; font-size:20px; line-height:1.7; font-weight:800; }
.guard-management-tools { display:grid; gap:12px; }
.guard-management-tools .wide-action { width:min(430px,100%); }
.temporary-password-note {
  display:block;
  margin-top:8px;
  padding:10px 12px;
  border-left:4px solid #b45309;
  border-radius:6px;
  background:#fffbeb;
  color:#78350f;
  font-size:15px;
  font-weight:800;
  line-height:1.55;
  overflow-wrap:anywhere;
}
.guard-management-table table { min-width:1040px; }
.guard-management-cards { display:none; }
.guard-management-card {
  display:grid;
  gap:12px;
  padding:16px;
  border:2px solid var(--line);
  border-radius:12px;
  background:#fff;
}
.guard-card-heading { display:flex; align-items:center; flex-wrap:wrap; gap:8px; font-size:22px; }
.guard-card-details { white-space:pre-line; font-size:18px; line-height:1.7; }
.worker-action-menu-wrap { position:relative; display:inline-flex; justify-content:flex-end; }
.worker-action-menu-button {
  width:52px !important;
  min-width:52px;
  min-height:52px;
  padding:0;
  border-radius:10px;
  font-size:32px;
  line-height:1;
}
.worker-action-menu {
  position:absolute;
  top:calc(100% + 6px);
  right:0;
  z-index:90;
  width:min(280px,calc(100vw - 36px));
  padding:8px;
  display:grid;
  gap:7px;
  border:3px solid var(--brand);
  border-radius:12px;
  background:#fff;
  box-shadow:0 14px 34px rgba(15,23,42,.28);
}
.worker-action-menu.table-floating-menu { position:fixed; z-index:1300; }
.worker-action-menu.mobile-portaled-menu {
  position:fixed;
  z-index:3000;
  max-height:calc(100dvh - 24px);
  overflow-y:auto;
  overscroll-behavior:contain;
}
.worker-action-menu[hidden] { display:none; }
.worker-action-menu button { width:100%; min-height:54px; padding:10px 14px; font-size:18px; text-align:left; }
.worker-action-menu .worker-menu-disable { color:#991b1b; background:#fff; border-color:#b91c1c; }
.integrated-management-actions {
  display:grid;
  grid-template-columns:minmax(260px,1fr) minmax(220px,auto);
  align-items:center;
  gap:12px;
  margin-bottom:20px;
}
.integrated-management-actions button { min-height:62px; font-size:20px; }
.integrated-management-actions .small-text { grid-column:1 / -1; margin:0; }
.worker-action-unavailable, .restore-admin-only {
  display:inline-block;
  padding:10px;
  color:#475569;
  font-size:16px;
  font-weight:800;
}
.account-status-confirm-message { white-space:pre-line; }
.proxy-input-banner {
  display:grid;
  gap:8px;
  margin-bottom:18px;
  padding:18px;
  border:4px solid #b45309;
  border-radius:12px;
  background:#fffbeb;
  color:#111827;
}
.proxy-input-banner > span,
.proxy-input-banner > strong { display:block; }
.proxy-input-warning {
  padding:10px 14px;
  border:3px solid #b91c1c;
  border-radius:10px;
  background:#fff1f2;
  color:#881337;
  font-size:20px;
}
.departure-time-selects {
  display:grid;
  grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);
  align-items:end;
  gap:10px;
  margin:0;
  padding:0;
  border:0;
}
.departure-time-selects legend { margin-bottom:10px; font-weight:900; }
.departure-time-selects label { margin:0; }
.departure-time-selects select { min-height:64px; font-size:28px; font-weight:900; text-align:center; }
.departure-time-selects > span { padding-bottom:13px; font-size:28px; font-weight:900; }
.progress-action-confirm-modal { padding:28px; border-radius:14px; }
.progress-action-confirm-modal .operation-confirm-message { margin:8px 0 24px; font-size:23px; line-height:1.65; }
.progress-confirm-actions button { min-width:180px; min-height:60px; font-size:20px; }
.proxy-input-banner strong { font-size:28px; }
.proxy-input-banner span { font-size:21px; font-weight:800; }
.proxy-input-banner button { width:min(360px,100%); }
.proxy-input-banner[hidden] { display:none; }
.own-shifts-list { display:grid; gap:18px; }
.own-shifts-section { display:grid; gap:14px; margin-top:24px; }
.own-shifts-section-title { margin:0; padding-bottom:8px; border-bottom:3px solid var(--brand); color:var(--brand); font-size:28px; }
.load-more-shifts { width:min(320px,100%); margin:4px auto 0; }
.own-shift-card {
  display:grid;
  gap:13px;
  padding:20px;
  border:3px solid var(--brand);
  border-radius:14px;
  background:#fff;
  box-shadow:0 5px 16px rgba(15,23,42,.12);
}
.own-shift-card.shift-night { border-color:#5b21b6; background:#faf5ff; }
.own-shift-card.is-past { border-color:#64748b; background:#f8fafc; }
.next-shift-label {
  width:max-content;
  padding:5px 12px;
  border-radius:999px;
  background:#b45309;
  color:#fff;
  font-size:18px;
  font-weight:900;
}
.own-shift-heading { display:flex; align-items:center; flex-wrap:wrap; gap:12px; }
.own-shift-heading strong { font-size:28px; }
.own-shift-type {
  padding:6px 14px;
  border:3px solid currentColor;
  border-radius:999px;
  font-size:20px;
  font-weight:900;
}
.own-shift-card h2 { margin:0; color:#111827; font-size:27px; }
.own-shift-summary { display:grid; gap:7px; font-size:20px; line-height:1.55; }
.own-shift-detail-row { display:grid; grid-template-columns:150px minmax(0,1fr); gap:10px; padding:10px 0; border-bottom:1px solid var(--line); font-size:20px; line-height:1.55; }
.own-shift-detail-row strong { color:var(--brand); }
.shift-address-value { overflow-wrap:anywhere; }
.own-shifts-empty { padding:30px 20px; border:3px solid var(--line); border-radius:14px; background:#f8fafc; text-align:center; font-size:24px; font-weight:900; }
.own-shift-detail-modal { width:min(760px,100%); }
.own-shift-detail-body { display:grid; gap:2px; }
.map-link-button {
  display:inline-flex;
  width:max-content;
  min-height:52px;
  align-items:center;
  justify-content:center;
  padding:10px 18px;
  border:3px solid var(--brand);
  border-radius:10px;
  background:#fff;
  color:var(--brand);
  font-size:18px;
  font-weight:900;
  text-decoration:none;
}
.map-link-button.disabled { color:#64748b; border-color:#94a3b8; background:#f1f5f9; cursor:not-allowed; }
.map-address-link { color:#075985; font-weight:900; text-decoration:underline; overflow-wrap:anywhere; }
.map-address-link.disabled { color:#64748b; text-decoration:none; cursor:default; }
.leader-members-button { min-height:62px; font-size:21px; }
.shift-members-modal { width:min(820px,100%); }
.shift-members-summary { white-space:pre-line; padding:14px; border:3px solid var(--brand); border-radius:10px; background:#ecfdf5; font-size:20px; font-weight:900; line-height:1.6; }
.shift-members-list { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; margin-top:14px; }
.shift-member-card { display:grid; gap:8px; padding:16px; border:2px solid var(--line); border-radius:12px; background:#fff; font-size:18px; line-height:1.6; }
.shift-member-card h3 { margin:0; font-size:23px; }
.shift-member-card > div { white-space:pre-line; }
.member-role { width:max-content; padding:4px 12px; border:2px solid #1d4ed8; border-radius:999px; color:#1e40af; background:#eff6ff; }
.member-role.leader { color:#78350f; border-color:#b45309; background:#fef3c7; }
.self-progress-section { display:grid; gap:12px; margin-top:18px; padding:16px; border:3px solid var(--brand); border-radius:12px; background:#f8fafc; }
.self-progress-section h3 { margin:0; font-size:25px; }
.departure-check-time { font-size:21px; font-weight:900; }
.self-progress-row { display:grid; grid-template-columns:150px minmax(120px,1fr) minmax(190px,auto); align-items:center; gap:10px; padding:12px 0; border-top:1px solid var(--line); font-size:19px; }
.self-progress-row button { min-height:58px; font-size:19px; }
.self-progress-row.is-complete { border-radius:8px; background:#ecfdf5; }
.self-progress-row.is-complete strong,
.self-progress-row.is-complete span { color:#166534; font-weight:900; }
.departure-contact-list { display:grid; gap:18px; }
.progress-toolbar { display:flex; align-items:end; flex-wrap:wrap; gap:14px; }
.progress-toolbar label { min-width:190px; }
.daily-progress-cards { display:none; }
.daily-progress-card { white-space:pre-line; padding:16px; border:2px solid var(--line); border-radius:12px; background:#fff; font-size:18px; line-height:1.6; }
.daily-progress-actions { display:grid; gap:8px; margin-top:12px; }
.daily-progress-actions button { width:100%; }
.progress-state { font-weight:900; white-space:nowrap; }
.progress-state.is-done { color:#166534; background:#ecfdf5; }
.progress-state.is-pending { color:#991b1b; background:#fff1f2; }
.guard-editor { width:min(850px,100%); }
.managed-fixed-values {
  display:flex;
  flex-wrap:wrap;
  gap:10px 18px;
  margin-top:18px;
  padding:14px;
  border:2px solid var(--brand);
  border-radius:10px;
  background:#ecfdf5;
  font-size:18px;
  font-weight:800;
}
input[readonly] { background:#e5e7eb; color:#374151; cursor:not-allowed; }
@media (max-width:1000px) and (min-width:761px) { .shift-groups { grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media (max-width:900px) {
  #adminScreen .kana-page-buttons { overflow-x:auto; overflow-y:hidden; }
}
@media (max-width:760px) {
  #adminScreen .integrated-management-actions { flex-wrap:wrap; }
  #adminScreen .integrated-management-actions button { flex:1 1 220px; }
  #adminScreen .integrated-management-actions .small-text { flex-basis:100%; }
  #adminScreen .admin-tools { grid-template-columns:1fr; }
  .admin-table-bottom-space { min-height:50vh; }
  .mobile-only-list { display:grid; }
  #accountApprovalsScreen .desktop-table,
  #passwordChangeRequestsScreen .desktop-table { display:block; overflow-x:auto; }
  .integrated-management-actions { grid-template-columns:1fr; }
  .integrated-management-actions .small-text { grid-column:auto; }
  .shift-toolbar { flex-direction:column; align-items:stretch; }
  .shift-toolbar label { min-width:0; }
  #shiftTypeDay { margin-left:0; }
  .shift-groups { grid-template-columns:1fr; }
  .candidate-row { align-items:stretch; flex-direction:column; }
  .availability-note-preview { width:100%; }
  .selected-member-row { align-items:stretch; flex-direction:column; }
  .group-card-heading { gap:8px; }
  .group-card-controls { gap:5px; }
  .completion-badge, .shift-status-badge { min-height:38px; padding:5px 9px; font-size:16px; }
  .shift-card-menu-button { width:50px !important; min-width:50px; min-height:50px; }
  .shift-card-menu { position:fixed; top:auto; right:12px; bottom:12px; left:12px; width:auto; }
  .guard-management-cards { display:grid; gap:14px; }
  .guard-management-card > button, .guard-management-card > .secondary { width:100%; }
  .worker-action-menu-wrap { width:100%; }
  .worker-action-menu-button { width:52px !important; margin-left:auto; }
  .worker-action-menu:not(.mobile-portaled-menu) { position:fixed; top:auto; right:12px; bottom:12px; left:12px; width:auto; }
  .managed-fixed-values { display:grid; }
  .own-shift-detail-row { grid-template-columns:1fr; gap:2px; }
  .own-shift-card { padding:16px; }
  .own-shift-heading strong { font-size:25px; }
  .shift-members-list { grid-template-columns:1fr; }
  .map-link-button { width:100%; }
  .self-progress-row { grid-template-columns:1fr; }
  .daily-progress-cards { display:grid; gap:12px; }
  .selected-members { grid-template-columns:1fr; }
  .member-section-heading { align-items:flex-start; flex-direction:column; gap:8px; }
  .leader-choices { display:grid; grid-template-columns:1fr; }
  #adminScreen .desktop-table { display:block; }
  #adminScreen .monthly-schedule-scroll { max-height:calc(100vh - 180px); }
  .monthly-schedule-table .schedule-name-head,
  .monthly-schedule-table .schedule-name-cell { width:150px; min-width:150px; max-width:150px; }
  .shift-editor-header { display:block; }
  .shift-editor-top-actions { display:grid; grid-template-columns:1fr; margin-bottom:14px; }
}

/* 申請管理はPC・スマホとも表形式へ統一し、重複するカード表示を出さない。 */
#accountApprovalsCards,
#passwordChangeRequestsCards { display:none !important; }
