:root {
  --bg: #eef1f6;
  --panel: #ffffff;
  --ink: #1f2430;
  --muted: #6f7585;
  --line: #e6e8ef;
  --purple: #7b5ad9;
  --purple-dark: #6546c5;
  --purple-soft: #f3edff;
  --green: #2baa72;
  --green-soft: #ebfaf2;
  --amber: #da9b20;
  --amber-soft: #fff6df;
  --rose: #d75980;
  --rose-soft: #fff0f5;
  --blue-soft: #eef3ff;
  --shadow: 0 24px 48px rgba(25, 34, 57, 0.12);
}
* { box-sizing: border-box; }
body { margin: 0; font-family: "Noto Sans JP", system-ui, -apple-system, sans-serif; color: var(--ink); background: linear-gradient(180deg, #f4f6fb 0%, #eceff6 100%); }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
.eyebrow { margin: 0 0 4px; color: var(--muted); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; }

.login-body { min-height: 100vh; display: grid; place-items: center; padding: 32px 16px; }
.login-shell { width: min(1180px, 100%); }
.login-card { background: var(--panel); border-radius: 28px; box-shadow: var(--shadow); padding: 28px; border: 1px solid rgba(123, 90, 217, .12); }
.login-hero { padding: 20px 22px; border-radius: 24px; background: linear-gradient(135deg, var(--purple) 0%, var(--purple-dark) 100%); color: #fff; margin-bottom: 22px; }
.login-hero h1 { margin: 0 0 8px; font-size: 38px; line-height: 1.05; }
.login-hero p, .login-hero .eyebrow { margin-top: 0; color: rgba(255,255,255,.88); }
.login-search-row { display: grid; grid-template-columns: 1fr auto; gap: 12px; margin-bottom: 18px; }
.login-search-row input, .search-inline input, .search-shell input, .approval-filter-form select, .approval-filter-form input, .drawer-form input, .drawer-form select, .drawer-form textarea { width: 100%; border: 1px solid #d9dce7; border-radius: 14px; padding: 12px 14px; background: #fff; }
.login-search-row button, .search-inline button, .primary-submit, .desktop-chip, .clock-action, .icon-action { border: 0; border-radius: 14px; cursor: pointer; }
.login-search-row button, .primary-submit { background: linear-gradient(180deg, var(--purple) 0%, var(--purple-dark) 100%); color: #fff; padding: 0 18px; font-weight: 700; }
.login-group { margin-top: 18px; }
.login-group-head { display: flex; justify-content: space-between; align-items: baseline; padding: 0 4px 10px; }
.login-group-head h2 { margin: 0; font-size: 18px; }
.login-group-head span { color: var(--muted); font-size: 13px; }
.login-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.login-user-card { margin: 0; }
.login-user-card button { width: 100%; height: 100%; border: 1px solid var(--line); background: #fff; border-radius: 22px; padding: 16px; display: grid; gap: 8px; align-content: start; text-align: left; box-shadow: 0 10px 24px rgba(29, 35, 48, .05); }
.login-user-card button:hover { border-color: #cdbdff; transform: translateY(-1px); }
.login-avatar, .mini-avatar, .team-fallback { width: 48px; height: 48px; border-radius: 999px; background: var(--purple-soft); display: inline-flex; align-items: center; justify-content: center; font-weight: 800; color: var(--purple-dark); }
.login-avatar-image, .mini-avatar-image, .team-photo { width: 48px; height: 48px; border-radius: 999px; object-fit: cover; background: #eceff6; }

.desktop-shell { min-height: 100vh; display: grid; grid-template-columns: 236px minmax(0,1fr); gap: 22px; padding: 22px; }
.admin-sidebar { background: linear-gradient(180deg, var(--purple) 0%, var(--purple-dark) 100%); color: #fff; border-radius: 28px; padding: 22px 18px; display: flex; flex-direction: column; box-shadow: var(--shadow); }
.sidebar-brand { display: grid; gap: 4px; padding: 6px 6px 18px; border-bottom: 1px solid rgba(255,255,255,.16); }
.sidebar-brand small { opacity: .84; }
.sidebar-brand strong { font-size: 18px; }
.sidebar-brand span { font-size: 13px; opacity: .9; }
.sidebar-nav { padding-top: 16px; display: grid; gap: 6px; }
.sidebar-link { display: flex; align-items: center; gap: 10px; border-radius: 14px; padding: 11px 12px; color: rgba(255,255,255,.86); }
.sidebar-link.is-active, .sidebar-link:hover { background: rgba(255,255,255,.18); color: #fff; }
.sidebar-icon { width: 22px; text-align: center; }
.sidebar-footer { margin-top: auto; padding-top: 18px; display: grid; gap: 10px; }
.sidebar-user-badge { background: rgba(255,255,255,.18); border-radius: 14px; padding: 12px; font-size: 13px; }
.sidebar-logout { text-align: center; padding: 11px 12px; border-radius: 14px; background: rgba(255,255,255,.12); }

.admin-main { min-width: 0; display: grid; grid-template-rows: auto auto 1fr; gap: 14px; }
.admin-header { background: var(--panel); border-radius: 24px; padding: 18px 22px; display: flex; justify-content: space-between; align-items: center; gap: 18px; box-shadow: 0 12px 28px rgba(29, 35, 48, .06); }
.admin-header h1 { margin: 0 0 6px; font-size: 30px; line-height: 1.05; }
.admin-header small { color: var(--muted); }
.admin-tools { display: flex; gap: 10px; flex-wrap: wrap; }
.desktop-chip { display: inline-flex; align-items: center; justify-content: center; min-height: 42px; padding: 0 16px; background: linear-gradient(180deg, var(--purple) 0%, var(--purple-dark) 100%); color: #fff; font-weight: 700; }
.desktop-chip.ghost, .ghost { background: var(--purple-soft); color: var(--purple-dark); }
.desktop-flash { background: #fff8dd; border: 1px solid #f6df8a; color: #6b5407; padding: 12px 16px; border-radius: 18px; font-weight: 700; }
.admin-surface { background: transparent; display: grid; gap: 14px; align-content: start; }
.desktop-panel, .desktop-hero { background: var(--panel); border-radius: 24px; box-shadow: 0 12px 28px rgba(29, 35, 48, .06); padding: 18px 20px; border: 1px solid rgba(123,90,217,.08); }
.desktop-hero { overflow: hidden; padding: 0; }
.desktop-panel-head { display: flex; justify-content: space-between; gap: 12px; align-items: center; margin-bottom: 14px; }
.desktop-panel-head h2, .hero-copy h2 { margin: 0; font-size: 28px; }
.panel-actions, .pill-row, .filter-actions, .report-actions, .approval-actions-inline { display: flex; gap: 10px; flex-wrap: wrap; }

.pill-row form { display: inline-flex; margin: 0; }
.narrow-panel { max-width: 860px; }

.desktop-stat-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 12px; margin-bottom: 14px; }
.desktop-stat { border-radius: 20px; padding: 16px; }
.desktop-stat small, .metric-tile small, .time-card small { display: block; color: var(--muted); margin-bottom: 8px; }
.desktop-stat strong, .metric-tile strong, .time-card strong { display: block; font-size: 28px; line-height: 1.1; }
.tone-blue { background: var(--blue-soft); }
.tone-indigo { background: var(--purple-soft); }
.tone-amber { background: var(--amber-soft); }
.tone-green { background: var(--green-soft); }
.tone-rose { background: var(--rose-soft); }

.desktop-chart-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.chart-box { background: linear-gradient(180deg, #faf8ff 0%, #fff 100%); border-radius: 22px; padding: 16px; }
.chart-box.green { background: linear-gradient(180deg, #effbf4 0%, #fff 100%); }
.chart-box h3 { margin: 0 0 12px; font-size: 20px; }
.chart-columns { height: 220px; display: flex; align-items: end; gap: 10px; }
.chart-columns.tall { height: 260px; }
.chart-columns.gratitude-bars { height: 180px; }
.chart-col { flex: 1; min-width: 0; display: grid; justify-items: center; align-items: end; gap: 8px; }
.chart-col i { width: 100%; max-width: 28px; min-height: 18px; border-radius: 12px 12px 4px 4px; background: linear-gradient(180deg, #9c83ed 0%, #7357d7 100%); }
.chart-box.green .chart-col i, .compact-green .chart-col i { background: linear-gradient(180deg, #53ca94 0%, #28a36a 100%); }
.chart-col.purple-light i { background: linear-gradient(180deg, #c8b5ff 0%, #8a69e7 100%); }
.chart-col span { font-size: 11px; color: var(--muted); }
.year-pill { padding: 8px 12px; border-radius: 999px; background: #f0eff8; color: #6657a2; font-size: 13px; }
.year-pill.is-active { background: var(--purple-soft); color: var(--purple-dark); font-weight: 700; }

.search-shell, .search-inline { display: flex; gap: 10px; margin-bottom: 14px; }
.search-shell input[disabled] { background: #f8f9fc; color: #9097a8; }

.gratitude-list, .report-stack, .approval-list, .approved-stack { display: grid; gap: 12px; }
.gratitude-group h3 { margin: 0 0 10px; font-size: 15px; color: var(--muted); }
.gratitude-row, .report-card, .approved-row, .record-line, .approval-row { border: 1px solid var(--line); border-radius: 18px; padding: 12px 14px; display: flex; gap: 12px; align-items: center; background: #fff; }
.row-head { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.row-head span, .approval-row p, .gratitude-row p, .report-card p { color: var(--muted); font-size: 13px; }
.grow { flex: 1; min-width: 0; }

.notice-stack { display: grid; gap: 10px; margin-bottom: 14px; }
.notice-card { border-radius: 18px; padding: 14px 16px; display: flex; justify-content: space-between; gap: 14px; align-items: center; border: 1px solid transparent; }
.notice-card strong { display: block; margin-bottom: 6px; }
.notice-card p { margin: 0; color: #4c5566; font-size: 13px; }
.notice-card.tone-green { background: var(--green-soft); border-color: #b9e8d0; }
.notice-card.tone-amber { background: var(--amber-soft); border-color: #f2d890; }
.notice-card.tone-neutral { background: #f4f6fb; border-color: #dde1eb; }
.notice-arrow { font-size: 20px; color: var(--muted); }
.time-card { text-align: center; padding: 28px 12px; border-radius: 20px; background: #f7f7fb; margin-bottom: 14px; }
.attendance-cta { display: flex; justify-content: center; margin-bottom: 14px; }
.clock-action { min-width: 280px; min-height: 64px; font-size: 26px; font-weight: 800; color: #fff; }
.clock-action.start { background: linear-gradient(180deg, var(--purple) 0%, var(--purple-dark) 100%); }
.clock-action.end { background: linear-gradient(180deg, #f0bf2e 0%, #d99a15 100%); }
.mini-bars { display: flex; gap: 8px; align-items: end; height: 140px; margin-bottom: 12px; }
.mini-bars .chart-col { gap: 6px; }
.compact-list .record-line strong { font-size: 15px; }

.pending-hero { display: grid; grid-template-columns: 300px 1fr; min-height: 210px; }
.hero-media { background: #d8d0ef; min-height: 210px; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hero-placeholder { width: 100%; height: 100%; display: grid; place-items: center; font-size: 36px; font-weight: 800; color: rgba(255,255,255,.88); background: linear-gradient(180deg, #c1b0f7 0%, #8f73eb 100%); }
.hero-copy { padding: 28px 24px; display: grid; align-content: end; gap: 10px; background: linear-gradient(180deg, var(--purple) 0%, var(--purple-dark) 100%); color: #fff; }
.hero-badge { display: inline-flex; align-items: center; width: fit-content; padding: 8px 12px; border-radius: 999px; background: rgba(255,255,255,.18); font-weight: 700; }
.approval-filter-form { display: grid; grid-template-columns: 1fr 1fr auto; gap: 12px; align-items: end; }
.approval-filter-form.compact { grid-template-columns: 1fr 1fr auto; }
.approval-filter-form label, .drawer-form label { display: grid; gap: 6px; }
.approval-filter-form span, .drawer-form span { color: var(--muted); font-size: 12px; font-weight: 700; }
.approval-group h3 { margin: 16px 0 10px; font-size: 16px; }
.approval-row { justify-content: space-between; align-items: center; }
.approval-meta { display: flex; gap: 12px; align-items: flex-start; }
.circle-mark { width: 18px; height: 18px; border-radius: 999px; border: 2px solid #d2d6e2; flex: none; margin-top: 2px; }
.icon-action { min-height: 38px; padding: 0 14px; font-weight: 700; }
.icon-action.approve { background: var(--green-soft); color: #177349; }
.icon-action.reject { background: var(--rose-soft); color: #af3f65; }
.metric-tile-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: 14px; }
.metric-tile { border-radius: 18px; padding: 14px; background: #f8f8fc; border: 1px solid var(--line); }
.approved-row { justify-content: space-between; }

.team-grid-admin { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.team-grid-card { border: 1px solid var(--line); border-radius: 20px; padding: 14px; display: flex; gap: 12px; align-items: center; background: #fff; }
.team-grid-copy { display: grid; gap: 4px; }
.team-grid-copy small { color: var(--muted); }
.team-photo.large, .team-fallback.large { width: 88px; height: 88px; }
.user-card-large { align-items: flex-start; }

.route-summary-box { background: #f6f1ff; border-radius: 18px; padding: 16px; margin-bottom: 16px; }
.route-summary-box p { margin: 0 0 12px; color: #504a61; }
.route-meta { display: flex; gap: 16px; flex-wrap: wrap; color: var(--muted); font-size: 13px; }
.route-table { width: 100%; border-collapse: collapse; }
.route-table th, .route-table td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.route-table th { color: var(--muted); font-size: 13px; }

.report-card { align-items: flex-start; }
.report-icon { width: 44px; height: 44px; border-radius: 14px; background: var(--purple-soft); color: var(--purple-dark); display: grid; place-items: center; font-weight: 800; flex: none; }
.report-meta { display: flex; gap: 8px; flex-wrap: wrap; color: var(--muted); font-size: 12px; margin-top: 8px; }
.report-meta span { background: #f5f6fb; border-radius: 999px; padding: 4px 10px; }

.tiny-badge { display: inline-flex; align-items: center; justify-content: center; min-height: 28px; padding: 0 10px; border-radius: 999px; font-size: 12px; font-weight: 700; }
.badge-open { background: var(--blue-soft); color: #3657a7; }
.badge-recorded { background: #eef2ff; color: #5666b8; }
.badge-pending { background: var(--amber-soft); color: #8f6612; }
.badge-approved { background: var(--green-soft); color: #177349; }
.badge-rejected { background: var(--rose-soft); color: #af3f65; }
.badge-muted { background: #eff1f5; color: #647086; }

.admin-drawer, .inline-drawer { position: fixed; top: 18px; right: 18px; width: min(420px, calc(100vw - 36px)); max-height: calc(100vh - 36px); overflow: auto; background: #fff; border-radius: 22px; box-shadow: var(--shadow); padding: 18px; z-index: 40; }
.inline-drawer { right: 40px; top: 120px; width: min(420px, calc(100vw - 80px)); }
.drawer-backdrop { position: fixed; inset: 0; background: rgba(20, 24, 38, .32); z-index: 30; }
.drawer-head, .inline-drawer-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.drawer-head h2, .inline-drawer-head h3 { margin: 0; font-size: 22px; }
.drawer-close { border: 0; background: #f3f5fa; width: 38px; height: 38px; border-radius: 12px; font-size: 24px; cursor: pointer; }
.drawer-form { display: grid; gap: 12px; }
.drawer-form.compact textarea { resize: vertical; }
.primary-submit { min-height: 46px; }
.view-user-list { display: grid; gap: 8px; }
.view-user-item { display: flex; gap: 10px; align-items: center; border: 1px solid var(--line); border-radius: 16px; padding: 10px 12px; }
.view-user-item.is-active { border-color: #c6b8ff; background: #faf8ff; }
.view-user-item span { display: grid; gap: 2px; }
.view-user-item small { color: var(--muted); }
.empty-inline { color: var(--muted); text-align: center; padding: 16px; }

@media (max-width: 1100px) {
  .desktop-shell { grid-template-columns: 1fr; }
  .admin-sidebar { order: 2; }
  .desktop-chart-grid, .desktop-stat-grid, .metric-tile-row, .team-grid-admin { grid-template-columns: 1fr; }
  .pending-hero { grid-template-columns: 1fr; }
  .approval-filter-form, .approval-filter-form.compact { grid-template-columns: 1fr; }
}

.muted-inline { color: var(--muted); }
.attendance-panel .attendance-head { align-items: flex-start; }
.notice-mini-btn { min-height: 36px; padding: 0 12px; border: 0; }
.attention-card { text-align: center; padding: 24px 18px 28px; background: linear-gradient(180deg, #fbfbff 0%, #f7f8fd 100%); }
.attention-card.is-open { border: 1px solid rgba(218,155,32,.35); }
.attention-card.is-closed { border: 1px solid rgba(123,90,217,.14); }
.time-card-status { margin: 8px 0 2px; font-size: 16px; font-weight: 700; }
.time-card-help { margin: 0 0 14px; color: var(--muted); }
.attendance-cta.inside { margin: 0; display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.attendance-cta.inside form { margin: 0; }
@media (max-width: 1100px) {
  .attendance-cta.inside { flex-direction: column; align-items: stretch; }
  .attendance-cta.inside form, .attendance-cta.inside button { width: 100%; }
  .clock-action { min-width: 0; width: 100%; }
}


/* Phase 2 UI polish */
.compact-head { align-items: center; }
.compact-head strong { max-width: 72%; display: inline-block; }
.appreciate-admin-screen .search-shell { margin-bottom: 18px; }
.feed-card-group { background: #fbfbff; border: 1px solid var(--line); border-radius: 20px; padding: 14px; }
.feed-style-row { padding: 10px 0; border: 0; border-bottom: 1px solid #eceef5; border-radius: 0; background: transparent; }
.feed-style-row:last-child { border-bottom: 0; }
.more-placeholder { margin-top: 14px; width: 100%; min-height: 42px; border-radius: 14px; border: 1px solid var(--line); background: #fff; color: var(--muted); }
.hero-subtext { margin: 0; color: rgba(255,255,255,.88); }
.fitted-hero { min-height: 260px; }
.pending-filter-panel { position: relative; }
.stacked-filter-form { grid-template-columns: 1fr 1fr auto; }
.tight-actions { justify-content: flex-end; }
.doc-fab { position: absolute; right: 18px; bottom: -24px; width: 52px; height: 52px; display: grid; place-items: center; border-radius: 999px; background: linear-gradient(180deg, var(--purple) 0%, var(--purple-dark) 100%); color: #fff; box-shadow: 0 16px 24px rgba(87, 60, 181, .25); font-size: 24px; }
.grouped-card { border: 1px solid var(--line); border-radius: 20px; padding: 14px; background: #fff; }
.grouped-card h3 { margin-top: 0; }
.approval-record-panel, .report-screen-panel, .team-board-panel { overflow: hidden; }
.approved-title-strip { background: linear-gradient(180deg, var(--purple) 0%, var(--purple-dark) 100%); color: #fff; border-radius: 20px; padding: 18px 18px; margin-bottom: 14px; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.approved-title-strip .eyebrow.light { color: rgba(255,255,255,.76); }
.approved-title-strip h2 { margin: 0; }
.round-icon-link { width: 42px; height: 42px; border-radius: 999px; display: grid; place-items: center; background: rgba(255,255,255,.18); color: #fff; font-size: 22px; }
.inline-two-row { align-items: end; }
.compact-metric-row { margin-top: 0; }
.attendance-head-tools { display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.slim-chip { min-height: 36px; padding: 0 12px; }
.compact-notice-row { padding-top: 12px; padding-bottom: 12px; }
.tall-mini-bars { height: 200px; }
.attendance-report-panel .chart-col i { max-width: 36px; }
.team-board-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.team-board-column { border: 1px solid var(--line); border-radius: 20px; background: linear-gradient(180deg, #fbfbff 0%, #fff 100%); overflow: hidden; }
.team-board-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 16px; background: #f5f1ff; color: #4d3f81; font-weight: 700; }
.team-board-list { display: grid; gap: 10px; padding: 12px; }
.team-board-card { display: flex; gap: 10px; align-items: center; border: 1px solid var(--line); border-radius: 16px; padding: 10px 12px; background: #fff; }
.route-meta-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.route-meta-grid small { display: block; color: var(--muted); margin-bottom: 6px; }
.route-meta-grid strong { display: block; }
.route-nav-row { display: flex; justify-content: space-between; gap: 10px; margin-top: 18px; }
.report-screen-stack .report-card { align-items: center; }
.report-arrow { font-size: 24px; color: var(--muted); }
@media (max-width: 1100px) {
  .team-board-grid, .route-meta-grid, .stacked-filter-form { grid-template-columns: 1fr; }
  .doc-fab { right: 14px; }
  .approved-title-strip { align-items: flex-start; }
}

/* Approval surface fit v1 */
.glide-stage-card { padding: 0; overflow: hidden; }
.approval-screen-shell, .team-screen-shell, .user-screen-shell, .route-screen-shell, .reports-screen-shell { max-width: 860px; }
.approval-photo-strip { height: 170px; background: #d8d0ef; }
.approval-photo-strip img { width: 100%; height: 100%; object-fit: cover; display: block; }
.approval-photo-placeholder { width: 100%; height: 100%; display: grid; place-items: center; background: linear-gradient(180deg, #ccbaff 0%, #8969e4 100%); color: rgba(255,255,255,.92); font-size: 72px; font-weight: 800; }
.approval-purple-head { display: flex; justify-content: space-between; align-items: center; gap: 14px; padding: 18px 22px; background: linear-gradient(180deg, var(--purple) 0%, var(--purple-dark) 100%); color: #fff; }
.approval-purple-head h2 { margin: 0 0 4px; font-size: 32px; line-height: 1.1; }
.approval-purple-head p { margin: 0; color: rgba(255,255,255,.84); }
.compact-head-row { border-bottom: 1px solid rgba(255,255,255,.08); }
.head-chip { background: rgba(255,255,255,.18); color: #fff; }
.approval-body-shell { padding: 18px 22px 22px; display: grid; gap: 16px; }
.approval-glide-form { display: grid; grid-template-columns: 1fr 1fr auto; gap: 12px; align-items: end; }
.approval-glide-form label { display: grid; gap: 6px; }
.approval-glide-form span { color: var(--muted); font-size: 12px; font-weight: 700; }
.approval-glide-form select, .approval-glide-form input, .glide-search-form input { width: 100%; border: 1px solid #d9dce7; border-radius: 14px; padding: 12px 14px; background: #fff; }
.approval-glide-tools { display: flex; gap: 10px; align-items: center; }
.round-fab-link { width: 46px; height: 46px; border-radius: 999px; display: inline-grid; place-items: center; background: linear-gradient(180deg, var(--purple) 0%, var(--purple-dark) 100%); color: #fff; font-size: 22px; box-shadow: 0 14px 22px rgba(88, 61, 183, .24); }
.round-fab-link.white-fab { background: rgba(255,255,255,.18); }
.approval-summary-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.summary-pill { display: inline-flex; align-items: center; min-height: 32px; padding: 0 12px; border-radius: 999px; background: var(--purple-soft); color: var(--purple-dark); font-weight: 700; }
.summary-pill.muted { background: #f1eef9; color: #7464ae; }
.summary-linkish { color: #7563a9; font-size: 13px; margin-left: auto; }
.approval-metric-strip { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 12px; }
.mini-metric-card { border-radius: 18px; border: 1px solid var(--line); background: linear-gradient(180deg, #fbfbff 0%, #fff 100%); padding: 14px; }
.mini-metric-card small { display: block; color: var(--muted); margin-bottom: 8px; }
.mini-metric-card strong { display: block; font-size: 24px; }
.approval-glide-list { display: grid; gap: 16px; }
.approval-user-block, .approval-date-block { display: grid; gap: 10px; }
.approval-user-head, .approval-date-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: 15px; color: #453d58; }
.approval-user-head span, .approval-date-head span { color: var(--muted); font-size: 12px; }
.approval-line-card { display: flex; justify-content: space-between; gap: 12px; align-items: center; padding: 12px 14px; border-radius: 18px; border: 1px solid var(--line); background: #fff; }
.approval-line-main { display: flex; gap: 12px; align-items: flex-start; min-width: 0; }
.approval-line-main.single-column { gap: 0; }
.approval-line-main strong { display: block; margin-bottom: 4px; }
.approval-line-main p { margin: 0 0 4px; color: var(--muted); font-size: 13px; }
.approval-line-main small { color: #8b90a0; }
.approval-line-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.approved-style { background: linear-gradient(180deg, #fcfbff 0%, #fff 100%); }
.pending-style { background: linear-gradient(180deg, #fff 0%, #fcfbff 100%); }
.glide-empty-state { border: 1px dashed #d7dceb; border-radius: 18px; padding: 26px; text-align: center; color: var(--muted); background: #fafbfe; }
.approved-sync-row { display: flex; justify-content: space-between; gap: 10px; align-items: center; color: var(--muted); font-size: 13px; padding-bottom: 2px; }
.approved-strip .mini-metric-card { background: #fbfbff; }
.compact-approved-form { grid-template-columns: 1fr 1fr auto; }
.glide-search-form { display: grid; grid-template-columns: 1fr auto; gap: 10px; }
.kanban-like-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 14px; }
.kanban-column-card { border: 1px solid var(--line); border-radius: 20px; background: linear-gradient(180deg, #fbfbff 0%, #fff 100%); overflow: hidden; }
.kanban-column-head { display: flex; justify-content: space-between; gap: 10px; align-items: center; padding: 14px 16px; background: #f3edff; color: #4c4182; }
.kanban-member-list { display: grid; gap: 10px; padding: 12px; max-height: 520px; overflow: auto; }
.kanban-member-card { display: flex; gap: 10px; align-items: center; border: 1px solid var(--line); border-radius: 16px; padding: 10px 12px; background: #fff; }
.user-grid-stage { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 14px; }
.user-portrait-card { border: 1px solid var(--line); border-radius: 22px; padding: 16px; background: linear-gradient(180deg, #fff 0%, #fbfbff 100%); display: grid; justify-items: center; text-align: center; gap: 8px; }
.user-portrait { width: 148px; height: 148px; border-radius: 999px; object-fit: cover; background: #edf0f7; }
.user-portrait.fallback { display: grid; place-items: center; font-size: 52px; font-weight: 800; color: var(--purple-dark); background: var(--purple-soft); }
.narrow-route-shell { max-width: 760px; }
.glide-route-summary { background: #f6f1ff; }
.glide-route-table { background: #fff; }
.centered-route-nav { justify-content: space-between; }
.static-report-search { grid-template-columns: 1fr auto; }
.report-feed-stack { display: grid; gap: 12px; }
.report-feed-card { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-radius: 18px; border: 1px solid var(--line); background: #fff; }
@media (max-width: 1100px) {
  .approval-screen-shell, .team-screen-shell, .user-screen-shell, .route-screen-shell, .reports-screen-shell { max-width: none; }
  .approval-glide-form, .compact-approved-form, .approval-metric-strip, .kanban-like-grid, .user-grid-stage, .glide-search-form { grid-template-columns: 1fr; }
  .approval-purple-head { align-items: flex-start; }
  .approval-line-card { flex-direction: column; align-items: stretch; }
  .approval-line-actions { justify-content: stretch; }
  .approval-line-actions form, .approval-line-actions button { width: 100%; }
  .round-fab-link { justify-self: start; }
}


/* Phase 3 approval bridge */
.approval-group-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 10px; }
.approval-group-head h3 { margin: 0; }
.approval-group-meta { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.detailed-row { gap: 18px; align-items: flex-start; }
.approval-copy { display: grid; gap: 4px; }
.approval-copy p { margin: 0; color: #50566a; }
.approval-copy small { color: var(--muted); }
.workflow-comment { margin-top: 4px; border-radius: 12px; background: #f6f7fb; color: #596176; padding: 8px 10px; font-size: 12px; }
.workflow-comment.subtle { background: #fbfbff; }
.grouped-approved-stack { display: grid; gap: 14px; }
.approved-row.detailed-row { padding-top: 12px; padding-bottom: 12px; border-bottom: 1px solid #eceef5; }
.approved-row.detailed-row:last-child { border-bottom: 0; }
@media (max-width: 1100px) {
  .approval-group-head { align-items: flex-start; flex-direction: column; }
}


.approval-section-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.approval-section-head strong { font-size: 18px; }
.approval-section-head span { color: var(--muted); font-size: 13px; }
.workflow-meta-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.workflow-meta-pill { display: inline-flex; align-items: center; min-height: 24px; padding: 0 10px; border-radius: 999px; background: #f5f6fb; color: #677186; font-size: 12px; }
.workflow-meta-pill.muted { background: #fbfbff; }
.approved-list .approval-line-card { display: grid; gap: 10px; }
.approved-list .approval-line-main { width: 100%; }
@media (max-width: 1100px) {
  .approval-section-head { flex-direction: column; align-items: flex-start; }
  .workflow-meta-row { flex-direction: column; align-items: flex-start; }
}


/* Approval glide polish v2 */
.approval-inline-search { display: grid; gap: 6px; min-width: 260px; }
.approval-inline-search span { color: var(--muted); font-size: 12px; font-weight: 700; }
.workflow-inline { display: block; color: #8b90a0; font-size: 12px; margin-top: 4px; }
.workflow-inline.emphasis { color: #5b4c86; }
@media (max-width: 1100px) {
  .approval-inline-search { min-width: 0; }
}

/* Admin surface support fit v1 */
.appreciate-screen-shell, .reports-screen-shell, .route-screen-shell, .user-screen-shell, .team-screen-shell { max-width: 860px; }
.head-actions-wrap { flex-wrap: wrap; justify-content: flex-end; }
.report-sections-stack, .gratitude-sections-stack { display: grid; gap: 14px; }
.report-date-group { display: grid; gap: 10px; }
.report-date-group h3 { margin: 0; font-size: 15px; color: var(--muted); }
.gratitude-feed-card .row-head strong, .report-feed-card .row-head strong { font-size: 15px; }
.gratitude-feed-card p, .report-feed-card p { margin: 0; }
.route-table-shell h3 { margin: 0 0 12px; font-size: 16px; color: #463d5c; }
.route-table-shell { display: grid; gap: 10px; }
.team-screen-shell .approval-body-shell, .user-screen-shell .approval-body-shell { gap: 18px; }
.user-screen-shell .user-grid-stage { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.user-screen-shell .user-portrait-card strong { font-size: 16px; }
.report-feed-card, .gratitude-feed-card { background: linear-gradient(180deg, #fff 0%, #fbfbff 100%); }
.appreciate-screen-shell .approval-body-shell, .reports-screen-shell .approval-body-shell { gap: 18px; }
.appreciate-screen-shell .summary-pill, .reports-screen-shell .summary-pill, .route-screen-shell .summary-pill,
.team-screen-shell .summary-pill, .user-screen-shell .summary-pill { background: rgba(255,255,255,.18); color: #fff; }
@media (max-width: 1100px) {
  .head-actions-wrap { justify-content: flex-start; }
}


/* Final surface fit v1 */
.admin-surface { justify-items: start; }
.dashboard-stage-shell, .attendance-stage-shell, .approved-screen-shell { max-width: 860px; }
.dashboard-stage-shell .approval-body-shell, .attendance-stage-shell .approval-body-shell, .approved-screen-shell .approval-body-shell { gap: 18px; }
.dashboard-stage-shell .desktop-stat-grid { margin-bottom: 0; }
.dashboard-stage-shell .chart-box h3, .attendance-stage-shell .desktop-panel-head h3 { font-size: 18px; }
.dashboard-stage-shell .year-pill { background: rgba(255,255,255,.18); color: #fff; }
.dashboard-stage-shell .year-pill.is-active { background: rgba(255,255,255,.28); color: #fff; }
.dashboard-stage-shell .metric-tile-row .metric-tile, .approved-screen-shell .approval-metric-strip .mini-metric-card { background: linear-gradient(180deg, #fbfbff 0%, #fff 100%); }
.dashboard-stage-shell .reduced-head, .attendance-stage-shell .reduced-head { margin-bottom: 0; }
.gratitude-analytics-block { display: grid; gap: 12px; }
.gratitude-analytics-block h3, .attendance-report-panel h3 { margin: 0; font-size: 20px; }
.attendance-stage-shell .time-card strong { font-size: 56px; }
.attendance-stage-shell .clock-action.end { min-width: 320px; min-height: 72px; font-size: 32px; }
.attendance-stage-shell .clock-action.start { min-width: 320px; min-height: 72px; font-size: 32px; }
.attendance-stage-shell .summary-pill { background: rgba(255,255,255,.18); color: #fff; }
.approved-screen-shell .approval-glide-form { grid-template-columns: 1fr 1fr auto; }
.approved-screen-shell .approval-glide-tools { justify-content: flex-end; }
.approved-screen-shell .workflow-comment.subtle { margin-top: 8px; padding: 8px 10px; border-radius: 12px; background: #f7f8fc; color: #596274; font-size: 12px; }
.approved-screen-shell .tiny-badge.badge-approved { min-width: 68px; }
@media (max-width: 1100px) {
  .dashboard-stage-shell, .attendance-stage-shell, .approved-screen-shell { max-width: none; }
  .approved-screen-shell .approval-glide-form { grid-template-columns: 1fr; }
}

/* Closing execute + working approval surface */
.working-screen-shell, .closing-execute-shell { max-width: 980px; }
.working-approval-shell, .closing-body-shell { gap: 18px; }
.working-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 14px; flex-wrap: wrap; }
.working-toolbar-meta { display: grid; gap: 4px; }
.working-toolbar-meta span { color: var(--muted); font-size: 13px; }
.working-toolbar-actions { display: flex; align-items: center; gap: 12px; }
.select-all-link { border: 0; background: transparent; color: #7563a9; font-weight: 700; cursor: pointer; }
.working-list-box { border: 1px solid var(--line); border-radius: 22px; background: #fff; padding: 18px 18px 8px; display: grid; gap: 18px; }
.working-user-group h3 { margin: 0 0 10px; font-size: 18px; }
.working-user-list { display: grid; gap: 12px; }
.working-row-card { display: grid; grid-template-columns: auto 1fr auto auto; align-items: center; gap: 14px; padding: 12px 8px; border-top: 1px solid #eceef5; }
.working-user-list .working-row-card:first-child { border-top: 0; }
.working-check-control { display: inline-grid; place-items: center; }
.working-check-control input { position: absolute; opacity: 0; pointer-events: none; }
.fake-radio { width: 22px; height: 22px; border-radius: 999px; border: 2px solid #8aa6e6; background: #fff; display: inline-block; }
.working-check-control input:checked + .fake-radio { background: var(--purple); border-color: var(--purple); box-shadow: inset 0 0 0 5px #fff; }
.working-row-copy { display: grid; gap: 4px; }
.working-row-copy small { color: #7b75a3; }
.working-row-copy strong { font-size: 14px; }
.working-row-copy p { margin: 0; color: #595e6d; font-size: 13px; }
.working-row-copy .red-dot::after { content: '●'; color: #f15252; margin-left: 4px; font-size: 10px; }
.detail-mini-btn { display: inline-flex; align-items: center; justify-content: center; min-width: 74px; min-height: 32px; padding: 0 12px; border-radius: 10px; background: #7a65d9; color: #fff; font-size: 12px; font-weight: 700; }
.detail-arrow { color: var(--muted); font-size: 22px; }
.working-overflow-note { color: var(--muted); font-size: 13px; margin: 0; }
.closing-top-row { display: flex; justify-content: space-between; align-items: end; gap: 12px; flex-wrap: wrap; }
.closing-filter-form { grid-template-columns: minmax(280px, 360px); }
.closing-warning-box { border-radius: 16px; padding: 14px 16px; background: #fdf1f1; color: #d04b4b; border: 1px solid #f1cccc; }
.closing-warning-box p { margin: 6px 0 0; font-size: 13px; color: #d04b4b; }
.execute-close-btn { min-height: 42px; padding: 0 18px; border: 0; border-radius: 14px; background: #f3f1f7; color: #444; font-weight: 800; cursor: pointer; }
.closing-summary-strip { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 12px; }
.closing-ready-card { border: 1px solid #d8ead7; background: #eff8ef; color: #2f6b2f; border-radius: 16px; padding: 16px; }
.closing-ready-card p { margin: 6px 0 0; color: #2f6b2f; }
.closing-empty-state { min-height: 180px; display: grid; place-items: center; color: #a4a9b8; }
.closing-blocker-pill { border-radius: 999px; background: #df3e29; color: #fff; padding: 10px 16px; font-size: 13px; font-weight: 700; }
.closing-blocker-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.closing-blocker-card { border: 1px solid #f0d0d0; border-radius: 16px; background: #fff7f7; padding: 14px; display: grid; gap: 4px; }
.closing-blocker-card p { margin: 0; color: #844; font-size: 13px; }
.closing-blocker-card small { color: #8c7a7a; }
@media (max-width: 1100px) {
  .working-row-card { grid-template-columns: auto 1fr; }
  .detail-mini-btn, .detail-arrow { grid-column: 2 / 3; justify-self: start; }
  .closing-summary-strip, .closing-blocker-grid, .closing-filter-form { grid-template-columns: 1fr; }
}


/* Closing execute alignment v2 */
.closing-fit-shell { gap: 16px; }
.closing-guide-row { display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: start; }
.closing-warning-box.compact { margin: 0; }
.closing-warning-box.compact strong { display: block; }
.closing-hint-pill { border-radius: 999px; padding: 10px 16px; font-size: 13px; font-weight: 700; }
.closing-hint-pill.pending { background: #f5f2dd; color: #7c6a1e; }
.closing-detail-drawer { border-top: 1px solid var(--line); padding-top: 10px; }
.closing-detail-drawer summary { cursor: pointer; color: var(--muted); font-weight: 700; margin-bottom: 10px; }
.closing-blocker-grid.compact { margin-top: 10px; }
@media (max-width: 1100px) {
  .closing-guide-row { grid-template-columns: 1fr; }
}

.closing-fix-help { border: 1px solid #eadfd0; border-radius: 16px; background: #fffaf2; padding: 14px 16px; display: grid; gap: 8px; }
.closing-fix-help p { margin: 0; color: #6e5f4c; font-size: 13px; }
.closing-fix-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.closing-blocker-card.actionable { gap: 8px; }
.closing-blocker-card.pending-tone { background: #fffaf1; border-color: #eddcb5; }
.closing-fix-copy { margin: 0; color: #6c5757; font-size: 13px; }
.closing-card-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.closing-card-actions .desktop-chip { min-height: 32px; }
.closing-jump-banner { border: 1px solid #d8d1f8; border-radius: 18px; background: #f7f4ff; padding: 14px 16px; display: grid; gap: 8px; }
.closing-jump-banner p { margin: 0; color: #675e8f; font-size: 13px; }
.closing-fix-list-panel, .attendance-fix-panel { border: 1px solid var(--line); border-radius: 20px; background: #fff; padding: 16px; display: grid; gap: 12px; }
.closing-fix-list-panel .compact-head, .attendance-fix-panel .compact-head { margin-bottom: 0; }
.closing-fix-list-box { padding-top: 8px; }
.action-row-card { grid-template-columns: 1fr auto; }
.working-inline-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.ghost-link { background: #f4f2fb; color: var(--purple-dark); }
.ghost-link:hover { background: #ebe6fb; }
.attendance-jump-banner { margin-bottom: 4px; }
.action-record-line { align-items: flex-start; }
.action-record-line .grow p { margin-top: 4px; }
@media (max-width: 980px) {
  .closing-card-actions, .working-inline-actions, .closing-fix-actions { flex-direction: column; }
  .action-row-card { grid-template-columns: 1fr; }
}

/* Closing admin quick-resolve tools */
.closing-inline-form { margin: 0; display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.closing-admin-all-form { border-top: 1px dashed #e2d6c8; padding-top: 10px; align-items: center; }
.closing-admin-all-form small { color: #7a6a58; font-size: 12px; }
.desktop-chip.admin-ok, .detail-mini-btn.admin-ok { background: #f0e9ff; color: var(--purple-dark); border: 1px solid #d8cdf8; }
.desktop-chip.admin-ok:hover, .detail-mini-btn.admin-ok:hover { background: #e7ddff; }
.detail-mini-btn.admin-ok.mini { min-width: 68px; }
.attendance-fix-actions { display: inline-flex; align-items: center; justify-content: flex-end; gap: 8px; flex-wrap: wrap; }
@media (max-width: 980px) {
  .closing-inline-form, .attendance-fix-actions { width: 100%; justify-content: flex-start; }
  .closing-inline-form .desktop-chip, .closing-inline-form .detail-mini-btn { width: 100%; }
}

/* Closing admin end-time resolve tools */
.closing-end-time-form { align-items: center; }
.closing-time-input {
  min-width: 92px;
  min-height: 34px;
  border: 1px solid #d8cdf8;
  border-radius: 12px;
  padding: 6px 10px;
  background: #fff;
  color: #241a3a;
  font-weight: 700;
}
.closing-admin-note {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 6px 10px;
  border-radius: 999px;
  background: #fff6dc;
  color: #7b5a00;
  border: 1px solid #f0dfa2;
  font-size: 12px;
  font-weight: 700;
}
@media (max-width: 980px) {
  .closing-time-input { width: 100%; }
  .closing-admin-note { width: 100%; justify-content: center; }
}

/* Closing restore checkpoint v5 */
.closing-restore-card {
  border: 1px solid #f1c7c7;
  border-radius: 16px;
  background: #fff7f7;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.closing-restore-card p {
  margin: 6px 0 0;
  color: #7d5353;
  font-size: 13px;
}
.desktop-chip.restore-danger {
  background: #fff;
  color: #b73333;
  border: 1px solid #e0aaaa;
}
.desktop-chip.restore-danger:hover { background: #ffeaea; }
@media (max-width: 980px) {
  .closing-restore-card { flex-direction: column; align-items: stretch; }
  .closing-restore-card .desktop-chip { width: 100%; }
}

/* Closing admin delete tools v6 */
.desktop-chip.admin-delete, .detail-mini-btn.admin-delete {
  background: #fff3f1;
  color: #b42318;
  border: 1px solid #f2b8b5;
}
.desktop-chip.admin-delete:hover, .detail-mini-btn.admin-delete:hover { background: #ffe3df; }
.detail-mini-btn.admin-delete.mini { min-width: 56px; }

/* Closing admin delete tools v7: allow deleting displayed closing blockers with audit log. */
.closing-admin-note { color: #8a5a00; font-size: 12px; }

/* closing mail sender v8 */
.closing-mail-card {
  margin: 18px 0 22px;
  padding: 22px;
  border-radius: 22px;
  border: 1px solid rgba(124, 92, 255, 0.22);
  background: linear-gradient(180deg, rgba(255,255,255,0.98), rgba(248,246,255,0.98));
  box-shadow: 0 16px 38px rgba(31, 42, 68, 0.08);
}
.closing-mail-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 16px;
}
.closing-mail-kicker {
  display: inline-flex;
  font-size: 12px;
  letter-spacing: 0.12em;
  color: #7a6aa8;
  margin-bottom: 5px;
}
.closing-mail-head h3 {
  margin: 0 0 6px;
  font-size: 24px;
  color: #12182d;
}
.closing-mail-head p {
  margin: 0;
  color: #5f6b7f;
  line-height: 1.7;
}
.closing-mail-status {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 9px 14px;
  font-weight: 800;
  font-size: 13px;
}
.closing-mail-status.ok {
  color: #136b3a;
  background: #e8f8ef;
  border: 1px solid #bfe8cd;
}
.closing-mail-status.ng {
  color: #a04400;
  background: #fff3df;
  border: 1px solid #f5d4a3;
}
.closing-mail-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(110px, 1fr));
  gap: 10px;
  margin: 14px 0;
}
.closing-mail-summary-grid > div {
  border: 1px solid #ece7ff;
  border-radius: 16px;
  padding: 13px 14px;
  background: #fff;
}
.closing-mail-summary-grid strong {
  display: block;
  font-size: 24px;
  color: #6d4ce8;
}
.closing-mail-summary-grid span {
  color: #68758b;
  font-size: 13px;
  font-weight: 700;
}
.closing-mail-small,
.closing-mail-alert {
  margin: 8px 0;
  font-size: 14px;
  color: #5a6475;
}
.closing-mail-alert {
  color: #b04500;
  background: #fff7eb;
  border: 1px solid #ffd9aa;
  border-radius: 12px;
  padding: 9px 12px;
}
.closing-mail-settings-form {
  margin-top: 16px;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid #ece7ff;
  background: #fff;
}
.closing-mail-field-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}
.closing-mail-settings-form label,
.closing-mail-test-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  color: #344054;
  font-weight: 800;
}
.closing-mail-settings-form input,
.closing-mail-settings-form textarea,
.closing-mail-test-form input {
  width: 100%;
  border: 1px solid #d9d6ea;
  border-radius: 12px;
  padding: 10px 12px;
  font: inherit;
  background: #fff;
  box-sizing: border-box;
}
.closing-mail-settings-form textarea {
  min-height: 260px;
  line-height: 1.65;
  resize: vertical;
}
.closing-mail-help {
  margin: 8px 0 14px;
  color: #6a7282;
  font-size: 13px;
  line-height: 1.7;
}
.closing-mail-help code {
  background: #f2edff;
  color: #6d4ce8;
  border-radius: 8px;
  padding: 2px 6px;
}
.closing-mail-actions-row {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(260px, 1fr);
  gap: 14px;
  margin: 16px 0;
}
.closing-mail-test-form,
.closing-mail-live-form {
  padding: 15px;
  border-radius: 18px;
  background: #fff;
  border: 1px solid #ece7ff;
  display: flex;
  flex-direction: column;
  gap: 10px;
  justify-content: space-between;
}
.execute-close-btn.mail-send {
  min-width: 140px;
  align-self: flex-start;
}
.closing-mail-preview {
  margin-top: 12px;
  border: 1px solid #ece7ff;
  border-radius: 18px;
  background: #fff;
  padding: 12px 14px;
}
.closing-mail-preview summary {
  cursor: pointer;
  font-weight: 900;
  color: #35415b;
}
.mail-preview-subject {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  background: #f6f3ff;
  color: #1d2440;
  font-weight: 900;
}
.closing-mail-preview pre {
  margin: 12px 0 0;
  white-space: pre-wrap;
  word-break: break-word;
  font-family: inherit;
  line-height: 1.75;
  color: #1f2937;
}
.closing-mail-log-list {
  margin-top: 12px;
  display: grid;
  gap: 8px;
}
.closing-mail-log-row {
  display: grid;
  gap: 3px;
  border-radius: 12px;
  padding: 10px 12px;
  background: #f8fafc;
  border: 1px solid #e5e7eb;
}
.closing-mail-log-row.sent {
  background: #f0fdf4;
  border-color: #bbf7d0;
}
.closing-mail-log-row.error {
  background: #fff1f2;
  border-color: #fecdd3;
}
.closing-mail-log-row span,
.closing-mail-log-row small {
  color: #667085;
}
@media (max-width: 980px) {
  .closing-mail-head,
  .closing-mail-actions-row,
  .closing-mail-field-row {
    grid-template-columns: 1fr;
    display: grid;
  }
  .closing-mail-summary-grid {
    grid-template-columns: repeat(2, minmax(110px, 1fr));
  }
}

.closing-excel-card {
  margin: 18px 0;
  padding: 18px 20px;
  border-radius: 22px;
  border: 1px solid #bfdbfe;
  background: linear-gradient(135deg, #eff6ff, #f8fafc);
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto;
  gap: 18px;
  align-items: center;
  box-shadow: 0 10px 28px rgba(37, 99, 235, 0.08);
}
.closing-excel-card h3 {
  margin: 4px 0 6px;
  color: #172554;
  font-size: 20px;
}
.closing-excel-card p {
  margin: 0 0 8px;
  color: #344054;
  line-height: 1.7;
}
.closing-excel-card small {
  color: #667085;
  font-weight: 700;
}
.closing-excel-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}
.excel-download {
  min-width: 180px;
  text-decoration: none;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  white-space: nowrap;
}
.excel-download[disabled] {
  opacity: .45;
  cursor: not-allowed;
}
@media (max-width: 980px) {
  .closing-excel-card {
    grid-template-columns: 1fr;
  }
  .closing-excel-actions {
    align-items: stretch;
  }
}

/* v16 go-live test users: ID/password login, account list, attendance log */
.credential-login-panel { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 18px; align-items: stretch; margin: 0 0 18px; }
.credential-login-copy { border-radius: 22px; padding: 20px; background: linear-gradient(180deg, #fbfaff 0%, #f5f1ff 100%); border: 1px solid rgba(123,90,217,.16); }
.credential-login-copy h2 { margin: 4px 0 8px; font-size: 24px; }
.credential-login-copy p { margin: 0; color: var(--muted); line-height: 1.65; }
.credential-login-form { border: 1px solid var(--line); border-radius: 22px; padding: 18px; display: grid; gap: 12px; background: #fff; box-shadow: 0 10px 24px rgba(29, 35, 48, .05); }
.credential-login-form label { display: grid; gap: 6px; }
.credential-login-form span { color: var(--muted); font-size: 12px; font-weight: 700; }
.credential-login-form input { width: 100%; border: 1px solid #d9dce7; border-radius: 14px; padding: 12px 14px; background: #fff; }
.credential-login-form button { border: 0; border-radius: 14px; min-height: 46px; cursor: pointer; background: linear-gradient(180deg, var(--purple) 0%, var(--purple-dark) 100%); color: #fff; font-weight: 800; }
.login-error { background: var(--rose-soft); color: #a73b5e; border: 1px solid #efbfd0; border-radius: 14px; padding: 10px 12px; font-weight: 700; }
.legacy-login-details { margin-top: 16px; border: 1px dashed #d7d2e8; border-radius: 20px; padding: 14px 16px; background: #fbfbff; }
.legacy-login-details summary { cursor: pointer; color: var(--purple-dark); font-weight: 800; }
.account-screen-shell, .attendance-log-shell { display: grid; gap: 14px; width: 100%; }
.account-hero, .log-hero { width: 100%; }
.account-hero-copy, .log-hero-copy { min-height: 190px; align-content: center; }
.account-hero-copy h2, .log-hero-copy h2 { margin: 0; font-size: 30px; }
.account-hero-copy p, .log-hero-copy p { margin: 0; max-width: 780px; color: rgba(255,255,255,.88); }
.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 2px; }
.section-head-row { display: flex; justify-content: space-between; gap: 14px; align-items: center; margin-bottom: 12px; }
.section-head-row h3 { margin: 0; font-size: 22px; }
.account-note { display: block; margin: -4px 0 14px; }
.account-table-wrap { width: 100%; overflow: auto; border: 1px solid var(--line); border-radius: 18px; }
.account-table { width: 100%; border-collapse: collapse; min-width: 960px; background: #fff; }
.account-table th, .account-table td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.account-table th { color: var(--muted); font-size: 12px; background: #fafbfe; white-space: nowrap; }
.account-table tr:last-child td { border-bottom: 0; }
.account-table code { background: #f4f2ff; color: var(--purple-dark); border-radius: 8px; padding: 4px 7px; font-weight: 800; }
.account-table small { color: var(--muted); }
.inline-action-form { margin: 0; }
.log-summary-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; width: 100%; }
.log-summary-card { background: #fff; border: 1px solid rgba(123,90,217,.10); border-radius: 20px; padding: 16px; box-shadow: 0 10px 24px rgba(29,35,48,.05); display: grid; gap: 4px; }
.log-summary-card small { color: var(--muted); font-weight: 700; }
.log-summary-card strong { font-size: 26px; }
.log-summary-card span { color: var(--muted); font-size: 12px; }
.log-list-panel { width: 100%; }
.log-timeline { display: grid; gap: 16px; }
.log-date-group h4 { margin: 8px 0 10px; color: var(--muted); font-size: 14px; }
.log-record-stack { display: grid; gap: 10px; }
.log-record-card { border: 1px solid var(--line); border-radius: 18px; background: #fff; padding: 12px; display: flex; gap: 12px; align-items: flex-start; }
.log-calendar-badge { width: 54px; min-width: 54px; height: 54px; border-radius: 16px; background: var(--purple-soft); color: var(--purple-dark); display: grid; place-items: center; align-content: center; }
.log-calendar-badge strong { font-size: 20px; line-height: 1; }
.log-calendar-badge span { font-size: 11px; font-weight: 800; }
.log-record-main { flex: 1; min-width: 0; }
.log-record-main p { margin: 4px 0 0; color: var(--muted); }
.source-badge { display: inline-flex; align-items: center; min-height: 28px; border-radius: 999px; padding: 0 10px; font-size: 12px; font-weight: 800; white-space: nowrap; }
.source-badge.source-new { background: var(--green-soft); color: #177349; }
.source-badge.source-imported { background: #f1f3f8; color: #60697d; }
.log-meta-row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; color: var(--muted); font-size: 12px; align-items: center; }
@media (max-width: 1100px) {
  .credential-login-panel { grid-template-columns: 1fr; }
  .log-summary-grid { grid-template-columns: 1fr 1fr; }
  .section-head-row, .row-head { align-items: flex-start; }
}
@media (max-width: 640px) {
  .log-summary-grid { grid-template-columns: 1fr; }
  .log-record-card { flex-direction: column; }
  .credential-login-copy h2, .account-hero-copy h2, .log-hero-copy h2 { font-size: 24px; }
}

/* v17 secure login / user credential visibility hotfix */
.login-body-secure { align-items: start; padding-top: 7vh; }
.secure-login-shell { width: min(720px, 100%); }
.secure-login-card { padding: 26px; }
.secure-login-hero { margin-bottom: 18px; }
.secure-login-hero h1 { margin-bottom: 0; }
.secure-login-hero p:not(.eyebrow) { display: none; }
.secure-login-panel { display: block; margin: 0; }
.secure-login-form { max-width: 420px; margin: 0 auto; }
.secure-login-form h2 { margin: 0 0 6px; font-size: 22px; }
.login-card .legacy-login-details { display: none !important; }
.user-management-v17 .head-actions-wrap { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.user-management-note { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin: 14px 0; padding: 12px 14px; border: 1px solid #e6e1f8; border-radius: 16px; background: #fbfaff; color: var(--muted); }
.user-management-note strong { color: var(--ink); }
.user-grid-stage-v17 { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.user-portrait-card-v17 { align-content: start; }
.user-portrait-card-v17 .user-portrait { width: 112px; height: 112px; }
.user-login-mini { width: 100%; display: grid; grid-template-columns: 86px minmax(0, 1fr); gap: 6px 8px; text-align: left; padding: 10px 12px; border-radius: 14px; background: #f7f5ff; border: 1px solid #e6e1f8; }
.user-login-mini span { color: var(--muted); font-size: 12px; font-weight: 800; }
.user-login-mini code { overflow-wrap: anywhere; font-weight: 800; color: var(--purple-dark); }
.user-login-mini em { color: var(--muted); font-style: normal; }
.user-card-actions-v17 { width: 100%; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.mini-link-button { min-height: 34px; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center; background: linear-gradient(180deg, var(--purple) 0%, var(--purple-dark) 100%); color: #fff; text-decoration: none; font-weight: 800; font-size: 13px; }
.mini-link-button.ghost { background: var(--purple-soft); color: var(--purple-dark); }
@media (max-width: 720px) {
  .login-body-secure { padding-top: 24px; }
  .secure-login-card { padding: 18px; }
  .user-card-actions-v17 { grid-template-columns: 1fr; }
}

/* v18_go_live_simplified_flow_marker: simplified punch buttons and monthly totals */
.attendance-total-strip {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 0 0 14px;
}
.attendance-total-card {
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 14px 16px;
  background: linear-gradient(180deg, #fbfbff 0%, #fff 100%);
  display: grid;
  gap: 4px;
}
.attendance-total-card small { color: var(--subtle); font-weight: 800; }
.attendance-total-card strong { font-size: 26px; line-height: 1.1; color: var(--ink); }
.attendance-total-card span { color: var(--muted); font-size: 12px; }
.attendance-triple-cta { align-items: stretch; }
.attendance-triple-cta form { flex: 1 1 180px; min-width: 180px; }
.attendance-stage-shell .attendance-triple-cta .clock-action { min-width: 0; width: 100%; min-height: 72px; font-size: 24px; }
.clock-action.leave { background: linear-gradient(180deg, #42a5a5 0%, #2f8585 100%); }
.clock-action:disabled { opacity: .45; cursor: not-allowed; filter: grayscale(.2); }
@media (max-width: 760px) {
  .attendance-total-strip { grid-template-columns: 1fr; }
}

/* v22_operational_simplify_marker: management color, searchable filters, and list-based correction */
.role-admin .admin-sidebar {
  background: linear-gradient(180deg, #24436f 0%, #2e5a96 48%, #1f335d 100%);
}
.role-admin .approval-purple-head,
.role-admin .desktop-chip:not(.ghost),
.role-admin .clock-action.start {
  background: linear-gradient(135deg, #315b96 0%, #456fd1 100%);
}
.role-admin .sidebar-link.is-active,
.role-admin .sidebar-user-badge,
.role-admin .desktop-chip.ghost {
  background: rgba(255,255,255,.18);
}
.role-approver .admin-sidebar {
  background: linear-gradient(180deg, #315f57 0%, #3d7b6a 48%, #264c47 100%);
}
.role-approver .approval-purple-head,
.role-approver .desktop-chip:not(.ghost),
.role-approver .clock-action.start {
  background: linear-gradient(135deg, #2f766d 0%, #38a08d 100%);
}
.drawer-hint {
  margin: -4px 0 12px;
  color: var(--muted);
  font-size: 13px;
}
.attendance-month-list-panel .desktop-panel-head small { display: block; margin-top: 4px; }
.attendance-edit-list { max-height: 720px; overflow: auto; padding-right: 4px; }
.attendance-edit-row { align-items: flex-start; }
.record-edit-details { position: relative; }
.record-edit-details summary { list-style: none; cursor: pointer; }
.record-edit-details summary::-webkit-details-marker { display: none; }
.inline-edit-form {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 10;
  width: min(520px, 88vw);
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 20px 60px rgba(25, 32, 56, .18);
}
.inline-edit-form label { display: grid; gap: 4px; font-size: 12px; color: var(--muted); font-weight: 800; }
.inline-edit-form input { min-height: 38px; border: 1px solid var(--line); border-radius: 10px; padding: 0 10px; font: inherit; }
.inline-edit-form button { align-self: end; }
@media (max-width: 920px) {
  .inline-edit-form { position: static; width: 100%; grid-template-columns: 1fr; margin-top: 10px; }
}

/* v29_admin_active_archive_marker: proxy target warning, selector hints, user archive list */
.target-warning-banner {
  border: 1px solid #f0b6b6;
  background: #fff1f1;
  color: #c92626;
  border-radius: 18px;
  padding: 12px 16px;
  font-weight: 900;
  display: grid;
  gap: 4px;
}
.target-warning-banner small { color: #c92626; font-weight: 700; }
.field-hint { display: block; margin-top: 4px; color: var(--muted); font-size: 12px; line-height: 1.45; }
.muted-pill { background: rgba(255,255,255,.18); color: inherit; border: 1px solid rgba(255,255,255,.22); }
.user-management-v29 .user-card-actions-v29 { grid-template-columns: 1fr 1fr; }
.user-card-actions-v29 form { margin: 0; grid-column: 1 / -1; }
.user-card-actions-v29 form button { width: 100%; border: 0; cursor: pointer; }
.archive-button { background: #f2f3f8; color: #6d7280; }
.archive-user-panel { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); }
.archive-user-panel .desktop-panel-head small { display: block; margin-top: 4px; color: var(--muted); }
.archive-user-list { display: grid; gap: 10px; }
.archive-user-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; border: 1px dashed #d9dce7; border-radius: 18px; padding: 12px 14px; background: #fafbfe; }
.archive-user-row p { margin: 4px 0; color: var(--muted); font-size: 13px; }
.archive-user-row small { color: var(--muted); }
.archive-user-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; justify-content: flex-end; }
.archive-user-actions form { margin: 0; }
.archive-user-actions button { border: 0; cursor: pointer; }
@media (max-width: 760px) {
  .archive-user-row { align-items: flex-start; flex-direction: column; }
  .archive-user-actions { width: 100%; justify-content: stretch; }
  .archive-user-actions .mini-link-button,
  .archive-user-actions form,
  .archive-user-actions button { width: 100%; }
}

/* v30_admin_mari_archive_glide_marker: read-only legacy Glide history rows */
.legacy-history-note {
  margin: 12px 0;
  border: 1px solid #c7d2fe;
  background: #eef2ff;
  color: #3730a3;
  border-radius: 14px;
  padding: 10px 14px;
  font-weight: 800;
}
.legacy-history-chip {
  border: 1px solid #c7d2fe;
  background: #eef2ff;
  color: #3730a3;
}


/* v36_attendance_ui_user_admin_marker: admin/承認者画面のスマホ幅崩れ防止とユーザー管理UI */
.user-create-panel-v36,
.invoice-help-v36 {
  margin: 18px 0;
  padding: 18px;
  border-radius: 22px;
  background: #ffffff;
  border: 1px solid rgba(148, 163, 184, 0.22);
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.07);
}
.user-create-panel-v36 h3,
.invoice-help-v36 strong {
  margin: 0 0 6px;
}
.user-create-form-v36,
.user-status-form-v36 {
  display: grid;
  gap: 10px;
}
.user-create-form-v36 {
  grid-template-columns: repeat(5, minmax(120px, 1fr));
  align-items: end;
  margin-top: 12px;
}
.user-create-form-v36 label,
.user-status-form-v36 label {
  display: grid;
  gap: 5px;
  font-size: 12px;
  color: #64748b;
}
.user-create-form-v36 input,
.user-create-form-v36 select,
.user-status-form-v36 select {
  width: 100%;
  border: 1px solid #dbe3ef;
  border-radius: 12px;
  padding: 9px 10px;
  background: #fff;
  color: #0f172a;
}
.user-status-form-v36 {
  width: 100%;
  margin-top: 12px;
  padding: 12px;
  border-radius: 16px;
  background: #f8fafc;
  grid-template-columns: 1fr 1fr auto;
  align-items: end;
}
.invoice-help-v36 {
  background: #fff8e6;
  color: #5c3b00;
}
.invoice-help-v36 p {
  margin: 6px 0 0;
  line-height: 1.7;
}
@media (max-width: 760px) {
  .desktop-shell {
    padding: 16px;
    gap: 16px;
  }
  .admin-header,
  .approval-purple-head.compact-head-row,
  .desktop-panel-head,
  .section-head-row {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }
  .admin-header h1,
  .approval-purple-head h2 {
    writing-mode: horizontal-tb;
    word-break: keep-all;
    overflow-wrap: anywhere;
    line-height: 1.2;
  }
  .admin-tools,
  .panel-actions,
  .head-actions-wrap {
    width: 100%;
    flex-wrap: wrap;
    justify-content: flex-start;
  }
  .admin-drawer {
    width: min(94vw, 420px);
  }
  .attendance-total-strip,
  .user-create-form-v36,
  .user-status-form-v36 {
    grid-template-columns: 1fr;
  }
  .user-portrait-card,
  .record-line,
  .attendance-edit-row,
  .archive-user-row {
    min-width: 0;
    overflow-wrap: anywhere;
  }
  .record-line,
  .attendance-fix-actions {
    align-items: flex-start;
    flex-wrap: wrap;
  }
  .account-table-wrap {
    overflow-x: auto;
  }
  .admin-sidebar {
    max-height: none;
  }
}


/* v37_attendance_breaks_alerts_marker: 前日以前未完了警告・月別履歴・離席時間表示 */
.previous-incomplete-alert-v37 {
  margin: 0 0 14px;
  border: 1px solid #fecaca;
  background: #fff1f2;
  color: #991b1b;
  border-radius: 18px;
  padding: 14px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.previous-incomplete-alert-v37 strong { display: block; font-size: 16px; }
.previous-incomplete-alert-v37 p { margin: 4px 0 0; color: #9f1239; line-height: 1.6; }
.monthly-total-history-v37 {
  margin: 0 0 14px;
  padding: 16px;
  border-radius: 22px;
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: 0 12px 28px rgba(29, 35, 48, .06);
}
.monthly-total-list-v37 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 10px;
}
.monthly-total-row-v37 {
  display: grid;
  gap: 6px;
  border: 1px solid #e6e8ef;
  border-radius: 16px;
  padding: 12px 14px;
  background: #fbfcff;
  text-decoration: none;
}
.monthly-total-row-v37 span { color: var(--muted); font-size: 12px; font-weight: 800; }
.monthly-total-row-v37 strong { color: var(--ink); font-size: 16px; }
.monthly-total-row-v37.is-active { border-color: #c7b8ff; background: #faf8ff; }
.today-break-card-v37 { background: #f8fafc; }

/* v37: adminスマホ画面での不明な棒グラフ表示・勤怠行重なりを抑止 */
@media (max-width: 760px) {
  body.desktop-body { overflow-x: hidden; }
  .desktop-shell { display: flex; flex-direction: column; padding: 10px; gap: 12px; }
  .admin-main { order: 1; width: 100%; min-width: 0; }
  .admin-sidebar { order: 2; width: 100%; border-radius: 22px; padding: 16px; }
  .admin-header { padding: 16px; border-radius: 20px; }
  .admin-header h1, .approval-purple-head h2 { font-size: 26px; writing-mode: horizontal-tb !important; word-break: keep-all; overflow-wrap: anywhere; }
  .attendance-stage-shell, .approval-body-shell, .attendance-report-panel { min-width: 0; overflow: visible; }
  .screen-attendance .mini-bars, .screen-attendance .tall-mini-bars { display: none !important; }
  .attendance-edit-list { max-height: none; overflow: visible; padding-right: 0; }
  .record-line, .attendance-edit-row, .day-summary-line { display: grid; grid-template-columns: 1fr; align-items: stretch; gap: 10px; }
  .record-line .grow, .attendance-edit-row .grow { min-width: 0; }
  .record-line .grow p, .attendance-edit-row .grow p { line-height: 1.55; overflow-wrap: anywhere; }
  .attendance-fix-actions { width: 100%; display: flex; align-items: flex-start; justify-content: flex-start; gap: 8px; flex-wrap: wrap; }
  .attendance-fix-actions .detail-mini-btn, .attendance-fix-actions form, .attendance-fix-actions button { max-width: 100%; }
  .previous-incomplete-alert-v37 { align-items: stretch; flex-direction: column; }
  .monthly-total-list-v37 { grid-template-columns: 1fr; }
}


/* v38_1_live_total_and_error_jump_marker: 未完了エラー通知を押せる見た目にし、日付入力ジャンプを分かりやすくする */
.previous-incomplete-alert-v37.clickable-v38 { cursor: pointer; }
.previous-incomplete-alert-v37.clickable-v38:focus-visible { outline: 2px solid #7c3aed; outline-offset: 2px; }
.previous-incomplete-alert-v37 .v38-jump-btn {
  border: 0;
  border-radius: 999px;
  padding: 8px 12px;
  font-weight: 900;
  color: #fff;
  background: linear-gradient(135deg, #7c3aed, #4f46e5);
  cursor: pointer;
}


/* v39_error_row_jump_and_compact_month_marker: エラー行ジャンプ・月別合計の折り畳み化 */
/* v39_2_template_only_error_row_jump_marker: main.pyを触らずテンプレート/JS/CSSだけで実装 */
.previous-incomplete-alert-v37.clickable-v39 { cursor: pointer; }
.previous-incomplete-alert-v37.clickable-v39:focus-visible { outline: 2px solid #dc2626; outline-offset: 2px; }
.previous-incomplete-alert-v37 .v39-jump-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  margin-top: 8px;
  border: 0;
  border-radius: 999px;
  padding: 8px 14px;
  background: linear-gradient(135deg, #7c3aed, #4f46e5);
  color: #fff;
  font-weight: 900;
  text-decoration: none;
  box-shadow: 0 8px 18px rgba(79, 70, 229, .22);
}
.record-error-row-v39 {
  border-color: #fecdd3 !important;
  background: #fff7f7 !important;
}
.record-error-help-v39 {
  margin-top: 8px;
  border: 1px solid #fecdd3;
  background: #fff1f2;
  color: #9f1239;
  border-radius: 12px;
  padding: 9px 10px;
  font-size: 12px;
  line-height: 1.55;
}
.record-error-help-v39 strong {
  display: block;
  margin-bottom: 2px;
  color: #be123c;
}
.v39-highlight-target {
  outline: 3px solid #f43f5e !important;
  outline-offset: 4px;
  box-shadow: 0 0 0 8px rgba(244, 63, 94, .12) !important;
}
.compact-month-v39 { margin-top: 14px; }
.monthly-total-accordion-v39 > summary {
  cursor: pointer;
  list-style: none;
  border: 1px solid #e4e8f2;
  border-radius: 16px;
  padding: 12px 14px;
  background: #fff;
  color: #4f46e5;
  font-weight: 900;
}
.monthly-total-accordion-v39 > summary::-webkit-details-marker { display: none; }
.monthly-total-accordion-v39 > summary::after {
  content: '＋';
  float: right;
  color: #7c3aed;
}
.monthly-total-accordion-v39[open] > summary::after { content: '－'; }
.monthly-total-list-v37.compact-v39 { margin-top: 10px; }
.compact-month-head-v39 { margin-top: 10px; }

/* v41_contractor_invoice_and_pending_breaks_marker: contractor invoice UI + pending break display polish */
.contractor-invoice-card-v41 {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(260px, 1.2fr);
  gap: 16px;
  align-items: start;
}
.contractor-invoice-actions-v41 {
  display: grid;
  gap: 8px;
}
.contractor-invoice-actions-v41 small,
.closing-test-note-v41 {
  color: #6b7280;
  line-height: 1.7;
  display: block;
}
.contractor-invoice-download {
  border-color: #f59e0b !important;
  background: #fff7ed !important;
  color: #92400e !important;
}
.contractor-invoice-one-download {
  border-color: #93c5fd !important;
  background: #eff6ff !important;
  color: #1d4ed8 !important;
}
.working-row-card strong {
  line-height: 1.55;
}
@media (max-width: 760px) {
  .contractor-invoice-card-v41 { grid-template-columns: 1fr; }
}


/* v42_source_separation_marker: source-mode tabs for new-system vs imported Glide data */
.source-mode-tabs-v42 { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 8px; }
.source-mode-tab { display: inline-flex; align-items: center; justify-content: center; padding: 9px 14px; border-radius: 999px; border: 1px solid #d6deef; background: #fff; color: #31507a; font-weight: 900; text-decoration: none; font-size: 13px; }
.source-mode-tab.is-active { background: #365fb6; color: #fff; border-color: #365fb6; box-shadow: 0 8px 20px rgba(54,95,182,.16); }
.source-mode-note-v42 { border: 1px solid #dbeafe; background: #eff6ff; color: #1e3a8a; border-radius: 14px; padding: 10px 12px; font-size: 12px; font-weight: 800; margin: 0 0 12px; }
.source-mode-note-v42.is-reference, .source-readonly-warning-v42 { border-color: #fed7aa; background: #fff7ed; color: #9a3412; }
.source-readonly-warning-v42 { border-radius: 14px; padding: 10px 12px; margin: 10px 0; font-weight: 900; font-size: 13px; }
.mobile-source-tabs-v42 { margin-top: 10px; }
@media (max-width: 520px) { .source-mode-tabs-v42 { display: grid; grid-template-columns: 1fr; } .source-mode-tab { width: 100%; } }


/* v43_reasoned_closing_blockers_marker: clear disabled reason for closing execute */
.closing-execute-disabled-card-v43 {
  display: grid;
  gap: 14px;
  border: 1px solid #fecaca;
  background: #fff1f2;
  color: #7f1d1d;
  border-radius: 18px;
  padding: 16px;
  margin: 14px 0 18px;
  box-shadow: 0 12px 28px rgba(127, 29, 29, .08);
}
.closing-execute-disabled-card-v43.tone-reference {
  border-color: #c7d2fe;
  background: #eef2ff;
  color: #1e3a8a;
}
.closing-execute-disabled-card-v43.tone-empty {
  border-color: #fde68a;
  background: #fffbeb;
  color: #78350f;
}
.closing-reason-kicker-v43 {
  display: inline-flex;
  width: fit-content;
  border-radius: 999px;
  background: rgba(220, 38, 38, .12);
  color: #b91c1c;
  font-size: 12px;
  font-weight: 900;
  padding: 5px 9px;
  margin-bottom: 8px;
}
.closing-execute-disabled-card-v43.tone-reference .closing-reason-kicker-v43 {
  background: rgba(79, 70, 229, .12);
  color: #3730a3;
}
.closing-execute-disabled-main-v43 strong {
  display: block;
  font-size: 16px;
  margin-bottom: 6px;
}
.closing-execute-disabled-main-v43 p,
.closing-primary-blocker-v43 p {
  margin: 0;
  line-height: 1.65;
  font-weight: 700;
}
.closing-primary-blocker-v43 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  border-top: 1px dashed rgba(127, 29, 29, .28);
  padding-top: 12px;
}
.closing-primary-blocker-v43 div:not(.closing-card-actions) {
  background: rgba(255,255,255,.72);
  border: 1px solid rgba(127, 29, 29, .12);
  border-radius: 14px;
  padding: 10px;
}
.closing-primary-blocker-v43 small {
  display: block;
  color: inherit;
  opacity: .72;
  font-weight: 900;
  margin-bottom: 4px;
}
.closing-primary-blocker-v43 b { font-size: 14px; }
.closing-primary-blocker-v43 p,
.closing-primary-blocker-v43 .closing-card-actions { grid-column: 1 / -1; }
.execute-close-btn.is-disabled-v43 {
  opacity: .48;
  filter: grayscale(.25);
  cursor: not-allowed;
}
.execute-disabled-note-v43 {
  display: block;
  margin-top: 8px;
  color: #991b1b;
  font-weight: 900;
  max-width: 220px;
}
.closing-row-reason-v43 {
  border: 1px solid #fecaca;
  background: #fff7f7;
  color: #7f1d1d;
  border-radius: 12px;
  padding: 9px 10px;
  margin: 8px 0;
  font-size: 13px;
  line-height: 1.55;
}
.closing-row-reason-v43 b { font-weight: 900; }
.closing-row-reason-v43 small {
  display: block;
  margin-top: 3px;
  color: #991b1b;
  font-weight: 800;
}
@media (max-width: 760px) {
  .closing-primary-blocker-v43 { grid-template-columns: 1fr; }
}


/* v44_closing_blocker_source_and_deep_link_marker: source label and exact timecard deep link */
.closing-source-badge-v44 {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  background: #eef2ff;
  color: #3730a3;
  font-size: 12px;
  font-weight: 900;
}
.primary-blocker-v44 div { align-items: flex-start; }
.strong-fix-link-v44 {
  border-color: #f59e0b !important;
  background: #fff7ed !important;
  color: #9a3412 !important;
  font-weight: 900 !important;
}
.closing-row-reason-v44 small { display: block; margin-top: 4px; }


/* v45_inputter_lock_after_approval_marker: lock inputter edits after approval or month close */
.inputter-lock-note-v45 {
  border: 1px solid #fecaca;
  background: #fff7ed;
  color: #7f1d1d;
  border-radius: 14px;
  padding: 12px 14px;
  margin: 10px 0;
  font-size: 13px;
  line-height: 1.55;
}
.inputter-lock-note-v45 strong { display: block; font-weight: 900; margin-bottom: 4px; }
.inputter-lock-note-v45 p { margin: 0; color: #7f1d1d; }
.inputter-lock-note-v45.compact { margin-top: 10px; padding: 10px 12px; }
.inputter-lock-note-v45.desktop { max-width: 280px; }

/* v45_1_inputter_lock_wording_inputfix_marker: wording/inputfix release. */


/* v46_inputter_edit_request_button_marker: correction request button and request list */
.inputter-edit-request-v46 { display: grid; gap: 8px; }
.edit-request-status-v46 { border: 1px solid #bfdbfe; background: #eff6ff; color: #1d4ed8; border-radius: 12px; padding: 8px 10px; font-weight: 800; font-size: 12px; }
.edit-request-form-v46 { border-top: 1px dashed rgba(37, 99, 235, .25); padding-top: 8px; }
.edit-request-form-v46 summary { cursor: pointer; font-weight: 900; color: #2563eb; }
.compact-request-form-v46 textarea, .request-inline-form-v46 textarea { width: 100%; border: 1px solid #d8deea; border-radius: 12px; padding: 10px; resize: vertical; font: inherit; }
.edit-request-panel-v46 { border: 1px solid #bfdbfe; background: #eff6ff; border-radius: 18px; padding: 14px; margin: 14px 0; }
.edit-request-list-v46 { display: grid; gap: 10px; }
.edit-request-card-v46 { background: #fff; border: 1px solid #dbeafe; border-radius: 16px; padding: 12px; display: flex; justify-content: space-between; gap: 12px; align-items: center; }
.edit-request-copy-v46 { display: grid; gap: 4px; min-width: 0; }
.edit-request-copy-v46 p { margin: 0; }
.edit-request-actions-v46 { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: flex-end; }
.edit-request-actions-v46 form { margin: 0; }
@media (max-width: 720px) { .edit-request-card-v46 { display: grid; } .edit-request-actions-v46, .edit-request-actions-v46.mobile { justify-content: flex-start; } }


/* v48_edit_request_confirm_allows_inputter_edit_marker: approved edit-request notice */
.edit-request-status-v46.approved-v48 {
  border: 1px solid #b7f0cb;
  background: #ecfdf3;
  color: #166534;
  border-radius: 12px;
  padding: 8px 10px;
  font-size: 12px;
  font-weight: 800;
  margin: 8px 0;
}

/* v49_user_identity_edit_marker: compact admin form for name/email/login ID corrections. */
.user-identity-form-v49 {
  width: 100%;
  margin-top: 12px;
  padding: 12px;
  border-radius: 16px;
  background: #fff7ed;
  border: 1px solid #fed7aa;
  display: grid;
  gap: 9px;
  text-align: left;
}
.user-identity-form-v49 label {
  display: grid;
  gap: 5px;
  font-size: 12px;
  color: #9a3412;
  font-weight: 800;
}
.user-identity-form-v49 input {
  width: 100%;
  border: 1px solid #fdba74;
  border-radius: 12px;
  padding: 9px 10px;
  background: #fff;
  color: #0f172a;
  font-weight: 700;
}
.user-identity-form-v49 small {
  color: #b45309;
  font-weight: 700;
}

/* v50_approver_identity_edit_marker: approver-visible identity form reuses v49 styling. */
.user-identity-form-v50 { border-style: solid; }


/* v51_approval_archive_closing_ui_marker: safer collapsed identity edit and production-closing warning. */
.user-identity-details-v51 {
  width: 100%;
  margin-top: 12px;
  text-align: left;
}
.user-identity-details-v51 > summary {
  cursor: pointer;
  list-style: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid #fed7aa;
  background: #fff7ed;
  color: #9a3412;
  border-radius: 999px;
  padding: 7px 11px;
  font-size: 12px;
  font-weight: 900;
}
.user-identity-details-v51 > summary::-webkit-details-marker { display: none; }
.user-identity-details-v51 > summary::after { content: '▼'; font-size: 10px; opacity: .75; }
.user-identity-details-v51[open] > summary::after { content: '▲'; }
.user-identity-details-v51 .user-identity-form-v49 { margin-top: 8px; }
.closing-production-warning-v51 {
  border-color: #fdba74 !important;
  background: linear-gradient(135deg, #fff7ed 0%, #fff 72%) !important;
}
.closing-production-warning-v51 strong { color: #9a3412; }
.closing-production-warning-v51 p { color: #7c2d12; }
.approved-row .approval-copy p { line-height: 1.55; }
