:root {

    --bg: #f4f6f9;

    --surface: #ffffff;

    --surface-soft: #f8fafc;

    --text: #1f2937;

    --muted: #6b7280;

    --line: #e5eaf0;

    --blue: #2f67b2;

    --blue-soft: #eaf2ff;

    --green: #147d64;

    --green-soft: #e8f6f1;

    --amber: #9a6500;

    --amber-soft: #fff4d9;

    --red: #b93838;

    --red-soft: #fff0f0;

    --radius: 14px;

    --shadow: 0 3px 14px rgba(26, 42, 67, .045);

  }

  

  body {

    margin: 0;

    background: var(--bg);

    color: var(--text);

    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans JP",

      "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;

    font-size: 16px;

    line-height: 1.55;

  }

  button, input, select { font: inherit; }

  button { cursor: pointer; }

  .app { min-height: 100vh; display: flex; }

  .main { min-width: 0; flex: 1; }

  .topbar {

    height: 72px; background: var(--surface); border-bottom: 1px solid var(--line);

    display: flex; align-items: center; justify-content: space-between;

    gap: 16px; padding: 0 30px;

  }

  .crumb { color: var(--muted); font-size: 16px; }

  .top-title { font-size: 19px; font-weight: 750; margin-top: 2px; }

  .top-actions { display: flex; align-items: center; gap: 10px; }

  .today-label { color: var(--muted); font-size: 16px; white-space: nowrap; }

  .avatar {

    width: 35px; height: 35px; border-radius: 50%; display: grid; place-items: center;

    background: #e5edf8; color: #284d7c; font-weight: 800; margin-left: 4px;

  }

  .menu-toggle {

    display: none; border: 1px solid var(--line); background: #fff; border-radius: 8px;

    width: 38px; height: 38px; color: var(--text);

  }

  .content { max-width: 1500px; margin: 0 auto; padding: 27px 30px 40px; }

  .welcome-row {

    display: flex; justify-content: space-between; align-items: flex-end;

    gap: 16px; margin-bottom: 21px;

  }

  h1 { font-size: 23px; margin: 0; letter-spacing: -.025em; }

  .welcome-sub { color: var(--muted); margin-top: 5px; font-size: 17px; }

  .date-chip {

    background: #fff; border: 1px solid var(--line); color: #4b5563;

    padding: 8px 12px; border-radius: 9px; white-space: nowrap; font-size: 16px;

  }

  .section-heading {

    display: flex; align-items: center; justify-content: space-between;

    gap: 12px; margin-bottom: 12px;

  }

  .section-heading h2 { margin: 0; font-size: 17px; font-weight: 750; }

  .section-help { color: var(--muted); font-size: 17px; }

  .metrics {

    display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));

    gap: 14px; margin-bottom: 25px;

  }

  .metric {

    background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);

    padding: 17px 18px; box-shadow: var(--shadow); min-width: 0;

  }

  .metric-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }

  .metric-label { color: #4b5563; font-size: 16px; font-weight: 650; }

  .metric-icon {

    width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px;

    font-size: 17px; flex-shrink: 0;

  }

  .metric-icon.blue { background: var(--blue-soft); color: var(--blue); }

  .metric-icon.green { background: var(--green-soft); color: var(--green); }

  .metric-icon.amber { background: var(--amber-soft); color: var(--amber); }

  .metric-icon.red { background: var(--red-soft); color: var(--red); }

  .metric-number { font-size: 29px; font-weight: 800; letter-spacing: -.04em; margin-top: 12px; }

  .metric-number span { font-size: 16px; font-weight: 600; margin-left: 4px; letter-spacing: 0; }

  .metric-foot { color: var(--muted); font-size: 17px; margin-top: 3px; }

  .metric-foot .attention { color: var(--red); font-weight: 700; }

  .grid-main { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .bottom-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin-top: 18px; }

  .panel {

    background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);

    box-shadow: var(--shadow); min-width: 0; overflow: hidden;

  }

  .panel-header {

    padding: 17px 19px 14px; display: flex; justify-content: space-between;

    align-items: center; gap: 12px; border-bottom: 1px solid var(--line);

  }

  .panel-title { margin: 0; font-size: 17px; font-weight: 750; }

  .panel-subtitle { margin-top: 3px; font-size: 17px; color: var(--muted); }

  .text-button {

    background: transparent; border: 0; color: var(--blue); padding: 5px 0;

    font-size: 16px; font-weight: 700; white-space: nowrap;

  }

  .text-button:hover { text-decoration: underline; }

  .schedule-list { padding: 4px 19px 10px; }

  .schedule-item {

    display: grid; grid-template-columns: 72px minmax(0, 1fr) auto; gap: 16px;

    align-items: start; padding: 13px 0; border-bottom: 1px solid #edf0f4;

  }

  .schedule-item:last-child { border-bottom: 0; }

  .schedule-time { font-weight: 800; font-size: 17px; color: #34445c; padding-top: 2px; }

  .schedule-main { min-width: 0; }

  .schedule-name { font-weight: 700; font-size: 17px; }

  .schedule-detail { color: var(--muted); font-size: 17px; margin-top: 3px; }

  .type-tag, .status-tag, .source-tag {

    display: inline-flex; align-items: center; white-space: nowrap; border-radius: 6px;

    font-size: 16px; font-weight: 700; padding: 4px 7px;

  }

  .type-tag.bodywork { background: #eaf2ff; color: #2f5d9a; }

  .type-tag.service { background: #eef2f5; color: #536273; }

  .type-tag.visit { background: #f2eaff; color: #7448a5; }

  .status-tag.wait { background: var(--amber-soft); color: var(--amber); }

  .status-tag.ready { background: var(--green-soft); color: var(--green); }

  .status-tag.work { background: var(--blue-soft); color: var(--blue); }

  .status-tag.late { background: var(--red-soft); color: var(--red); }

  .panel-footer {

    padding: 10px 19px 13px; border-top: 1px solid var(--line);

    color: var(--muted); font-size: 17px; background: #fcfdff;

  }

  .upcoming-list { padding: 0 18px; }

  .upcoming-item {

    display: grid; grid-template-columns: 54px minmax(0, 1fr) auto;

    align-items: center; gap: 11px; padding: 13px 0; border-bottom: 1px solid #edf0f4;

  }

  .upcoming-item:last-child { border-bottom: 0; }

  .date-box {

    border: 1px solid #dce5f1; border-radius: 9px; text-align: center; overflow: hidden;

    background: #f7faff;

  }

  .date-box .month { display: block; background: #e7effb; color: #45658e; font-size: 9px; padding: 3px; font-weight: 700; }

  .date-box .day { display: block; font-size: 20px; font-weight: 800; padding: 3px 0 5px; color: #263c59; line-height: 1.2; }

  .upcoming-main { min-width: 0; }

  .upcoming-name { font-weight: 750; font-size: 16px; }

  .upcoming-detail { color: var(--muted); font-size: 17px; margin-top: 4px; }

  .upcoming-right { text-align: right; }

  .upcoming-right .small-time { display: block; color: var(--muted); font-size: 16px; margin-top: 4px; }

  

  .compact-panel { padding-bottom: 3px; }

  .mini-list { padding: 3px 18px 10px; }

  .mini-row {

    display: flex; align-items: center; justify-content: space-between; gap: 12px;

    padding: 12px 0; border-bottom: 1px solid #edf0f4;

  }

  .mini-row:last-child { border-bottom: 0; }

  .mini-left { display: flex; align-items: center; gap: 10px; min-width: 0; }

  .mini-icon {

    width: 34px; height: 34px; display: grid; place-items: center; border-radius: 9px;

    background: var(--surface-soft); color: #53657a; font-size: 16px; flex-shrink: 0;

  }

  .mini-title { font-size: 16px; font-weight: 750; }

  .mini-detail { font-size: 16px; color: var(--muted); margin-top: 3px; }

  .mini-value { font-size: 17px; font-weight: 800; white-space: nowrap; }

  .mini-value small { font-size: 16px; color: var(--muted); font-weight: 600; }

  .priority-note {

    margin: 0 18px 14px; border-radius: 9px; background: #fff8e8; color: #805b16;

    padding: 10px 11px; font-size: 17px; display: flex; align-items: flex-start; gap: 8px;

  }

  .priority-note strong { color: #6b4a0c; }

  .footer-note { color: #8791a0; font-size: 16px; margin-top: 22px; text-align: right; }

  /* Prototype navigation feedback */

  .notice {

    display: none; margin-bottom: 18px; padding: 12px 14px; border-radius: 10px;

    background: #eef5ff; color: #284e7d; border: 1px solid #d5e5fb; font-size: 16px;

  }

  .notice.show { display: block; }

  @media (max-width: 1150px) {

    .content { padding: 24px 20px 32px; }

    .topbar { padding: 0 20px; }

    .metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }

    .grid-main { grid-template-columns: minmax(0, 1fr); }
    .bottom-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  }

  @media (max-width: 760px) {


    .app { display: block; }

    .menu-toggle { display: inline-grid; place-items: center; }

    .topbar { height: 64px; padding: 0 14px; }

    .top-title { font-size: 16px; }

    .crumb, .today-label { display: none; }

    .content { padding: 20px 14px 30px; }

    .welcome-row { align-items: flex-start; flex-direction: column; }

    h1 { font-size: 21px; }

    .metrics { gap: 10px; }

    .metric { padding: 14px; }

    .metric-number { font-size: 25px; }

    .grid-main, .bottom-grid { grid-template-columns: minmax(0, 1fr); }

    .schedule-item { grid-template-columns: 52px minmax(0, 1fr); gap: 9px; }

    .schedule-item > .status-tag { grid-column: 2; justify-self: start; }

    .upcoming-item { grid-template-columns: 50px minmax(0, 1fr); }

    .upcoming-right { grid-column: 2; text-align: left; display: flex; align-items: center; gap: 8px; }

    .upcoming-right .small-time { margin-top: 0; }

  }

  @media (max-width: 420px) {


    .metrics { grid-template-columns: 1fr 1fr; }

    .metric-label { font-size: 17px; }

    .metric-icon { width: 29px; height: 29px; }

    .metric-number { font-size: 23px; }

    .panel-header { padding-left: 14px; padding-right: 14px; }

    .schedule-list, .upcoming-list { padding-left: 14px; padding-right: 14px; }

    .panel-footer { padding-left: 14px; padding-right: 14px; }

  }

  /* 読みやすさ改善：全体の文字を大きめに調整 */

  body { font-size: 16px; line-height: 1.65; }

  .page-title, h1 { font-size: 28px; }

  .section-heading h2 { font-size: 19px; }

  .metric-label, .stat-label, .section-help { font-size: 14px; }

  .metric-value, .stat-value { font-size: 30px; }

  .metric-detail, .mini-detail, .footer-note { font-size: 13px; }

  .topbar, .topbar * { font-size: 14px; }

  button, input, select { font-size: 15px; }

  @media (max-width: 760px) {


    body { font-size: 16px; }

    .page-title, h1 { font-size: 24px; }

  }

/* KPI typography only; page header/layout remains page-specific */
.metrics .metric-label{font-size:14px;line-height:1.5;}
