:root {
  color-scheme: light; --ink: #17261d; --dark: #163729; --muted: #4a5a4e;
  --lime: #d6fa53; --surface: #fff; --paper: #f6f6ee; --line: #cdd4c5;
  --error: #912e35; --shadow: 0 12px 36px #183e320b;
  --display: 'Arial Black', Arial, sans-serif;
  font-family: 'Hiragino Kaku Gothic ProN', 'Yu Gothic', YuGothic, 'Noto Sans JP', Meiryo, sans-serif;
  line-height: 1.55; color: var(--ink); background: var(--paper);
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-height: 100dvh; overflow-wrap: anywhere; }
a { color: inherit; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .55; }
:is(button,a,input,select,textarea,summary):focus-visible { outline: 3px solid #497e3f; outline-offset: 3px; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: clamp(1.75rem, 4vw, 3.1rem); line-height: 1.16; letter-spacing: -.05em; }
h2 { font-size: clamp(1.2rem, 2.6vw, 1.6rem); line-height: 1.3; letter-spacing: -.02em; }
h3 { font-size: 1.02rem; line-height: 1.35; }
p + p { margin-top: .65em; }
small, .small { font-size: .83rem; }
.muted { color: var(--muted); }
.skip-link { position: fixed; z-index: 99; left: 14px; top: 10px; transform: translateY(-200%); padding: 10px 16px; background: #fff; }
.skip-link:focus { transform: none; }
.site-header { background: var(--paper); border-bottom: 1px solid var(--line); }
.header-inner { max-width: 1160px; min-height: 72px; margin: auto; padding: 10px 24px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.brand { display: inline-flex; align-items: center; gap: 9px; text-decoration: none; font: 900 clamp(24px, 2.5vw, 35px)/1 var(--display); letter-spacing: -.075em; white-space: nowrap; }
.brand-name { letter-spacing: -.03em; }
.brand small { display: block; margin-top: 4px; font-size: .56rem; letter-spacing: .16em; color: var(--muted); }
.header-actions, .session-menu { display: flex; align-items: center; gap: 8px; min-width: 0; }
.session-name { max-width: 15ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 700; font-size: .85rem; }
.auth-shell, .workspace { max-width: 1160px; margin: auto; padding: 28px 24px 40px; }
.auth-shell { display: grid; grid-template-columns: 1.12fr .88fr; gap: 26px; align-items: stretch; padding-top: clamp(24px, 6vh, 62px); }
.intro-panel { min-width: 0; overflow: hidden; display: flex; flex-direction: column; align-items: flex-start; justify-content: space-between; min-height: 475px; padding: clamp(26px, 4vw, 52px); border-radius: 26px; background: var(--dark); color: #fff; }
.intro-panel h1 { max-width: 13em; margin: 24px 0 18px; }
.intro-panel p { max-width: 34ch; color: #d5e7dc; }
.intro-panel .eyebrow { color: var(--lime); }
/* 導入パネルのコート（ピックルボール。真上から見た図）。外形 44ft×20ft＝2.2:1、ネットから両側 7ft がキッチン（ノンボレーゾーン）。
   viewBox は 1ft＝10。描画は web/app.js の SVG（コートの絵修正_指示書_v1） */
.intro-court { display: block; width: min(270px, 75%); height: auto; aspect-ratio: 44 / 20; margin-top: 32px; overflow: visible; }
.intro-court .court-surface { fill: #284d3e; }
.intro-court .court-kitchen { fill: #2f5847; }
.intro-court .court-lines { fill: none; stroke: #d6e8cc; stroke-width: 3; }
.intro-court .court-net { stroke: #eef5e8; stroke-width: 5; stroke-linecap: round; }
.intro-court .court-ball { fill: var(--lime); }
.auth-panel { display: grid; align-content: center; gap: 15px; padding: clamp(22px, 3vw, 42px); }
.auth-panel form { display: grid; gap: 13px; }
.auth-panel .btn.primary { width: 100%; margin-top: 3px; }
.auth-panel .switch-form { justify-self: start; padding-left: 0; border-color: transparent; background: transparent; text-decoration: underline; }
.auth-scoreboard-entry { border-top: 1px solid var(--line); padding-top: 12px; }
.auth-scoreboard-entry a { display: inline-flex; align-items: center; min-height: 44px; padding-block: 6px; color: var(--muted); font-size: .88rem; text-underline-offset: 3px; }
.auth-role-switch { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; padding: 4px; border: 1px solid var(--line); border-radius: 12px; background: #eef2e7; }
.auth-role-switch a { display: grid; place-items: center; min-height: 44px; padding: 5px; border-radius: 8px; font-weight: 750; text-align: center; text-decoration: none; }
.auth-role-switch a:hover { background: #dfe9d9; }
.auth-role-switch a[aria-current="page"] { background: var(--dark); color: white; }
.auth-role-badge { justify-self: start; }
.field { display: grid; gap: 5px; min-width: 0; font-size: .9rem; font-weight: 650; }
input:not([type="checkbox"]):not([type="radio"]), select, textarea { display: block; width: 100%; min-width: 0; min-height: 45px; padding: 9px 11px; border: 1px solid #bbcfbf; border-radius: 9px; background: #fff; color: var(--ink); }
input[type="checkbox"], input[type="radio"] { accent-color: #386548; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 5px; min-height: 44px; padding: 8px 13px; border: 1px solid #bfd0c1; border-radius: 10px; background: #fff; color: var(--ink); font-weight: 700; text-decoration: none; text-align: center; }
.btn:hover { background: #edf5e9; }
.btn.primary, .primary { background: var(--lime); color: var(--dark); border-color: #bedb54; }
.btn.primary:hover { background: #c9ed58; }
.btn.secondary { background: #eff4eb; color: var(--ink); }
.btn.danger { border-color: #d8a2a5; color: var(--error); }
.language-button { min-width: 44px; padding-inline: 9px; font-size: .82rem; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); padding: clamp(15px, 2vw, 25px); min-width: 0; }
.eyebrow { font-size: .72rem; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.eyebrow.service-name { letter-spacing: .04em; text-transform: none; }
.badge { display: inline-flex; border-radius: 999px; padding: 4px 9px; background: #e8f1e0; color: #294f36; font-size: .76rem; font-weight: 730; line-height: 1.4; }
.notice, .empty { border: 1px solid var(--line); padding: 11px 13px; border-radius: 11px; background: #edf4e9; }
.empty { color: var(--muted); }
.notice.error, .error { color: var(--error); }
.row, .section-head { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.section-head { justify-content: space-between; }
.grid, .stack { display: grid; gap: 16px; min-width: 0; }
.stack { gap: 13px; }
.loading { padding: 32px; text-align: center; color: var(--muted); }
.site-footer { max-width: 1160px; margin: auto; padding: 12px 24px 24px; color: var(--muted); font-size: .82rem; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; }
.site-footer-links { display: flex; flex-wrap: wrap; column-gap: 14px; }
.site-footer-links a { display: inline-flex; align-items: center; min-height: 44px; text-underline-offset: 3px; }
.site-policy { max-width: 760px; margin: 0 auto; }
.site-policy h1 { margin-bottom: 12px; }
.site-policy section { margin-top: 24px; }
.site-policy h2 { margin-bottom: 8px; }
.global-toast { position: fixed; z-index: 30; inset: auto 16px max(16px, env(safe-area-inset-bottom)) auto; max-width: min(430px, calc(100% - 32px)); padding: 12px 16px; background: var(--dark); color: #fff; border-radius: 12px; box-shadow: var(--shadow); overflow-wrap: anywhere; }
.global-toast.is-error { background: #74252e; }
dialog { max-width: min(540px, calc(100% - 32px)); max-height: 88dvh; border: 1px solid var(--line); border-radius: 16px; padding: 22px; color: var(--ink); }
dialog::backdrop { background: #122b23a6; }
.account-dialog { width: min(430px, calc(100% - 32px)); }
.account-dialog > p, .account-dialog .row { margin-top: 12px; }
.account-email { margin-top: 12px; }
.account-email input { cursor: text; }
.account-setting { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.account-setting summary { cursor: pointer; font-weight: 750; }
.account-setting form { margin-top: 10px; }
.account-billing [data-billing-content] { display: grid; gap: 9px; margin-top: 9px; }
.account-billing [data-billing-content] > .row { margin-top: 0; }
.account-billing [data-billing-message]:empty { display: none; }
.account-billing [data-billing-message] { margin-top: 7px; }
.account-billing-summary { display: grid; gap: 6px; margin: 0; }
.account-billing-summary > div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 7px; padding: 7px 0; border-bottom: 1px solid var(--line); }
.account-billing-summary dd { margin: 0; font-weight: 750; }
.btn.account-logout { color: #fff; background: #ab2635; border-color: #ab2635; }
.btn.account-logout:hover { background: #8f202d; border-color: #8f202d; }
.account-support > p { margin-top: 5px; }
.account-support [data-support-content] { margin-top: 8px; }
.support-options > summary { padding-block: 10px; min-height: 44px; color: var(--ink); }
.support-choices { display: grid; gap: 10px; margin-top: 4px; }
.support-choice > .btn { display: flex; width: 100%; }
.support-choice > p, .support-options > p { margin-top: 5px; }
.google-signin { display: grid; gap: 8px; min-width: 0; margin-top: 8px; padding-top: 12px; border-top: 1px solid var(--line); }
.google-signin p { font-size: .88rem; }
[data-google-slot] { min-width: 0; }
/* Google large is 40px tall. Keep only the matching auth actions at that size. */
.auth-panel #google-signin,
.auth-panel #continue-email,
.auth-panel #request-email-again { width: 100%; max-width: 400px; justify-self: start; }
.auth-panel #google-signin [data-google-slot] { min-height: 40px; }
/* 自作の Google ボタン（Googleボタン表記変更_指示書_v1）。Google のブランドガイドラインの
   白背景・グレーの枠・正規の G マーク。幅と高さは「メールで続ける」とそろえる（最大 400px × 40px）。 */
.auth-panel .google-button { width: 100%; max-width: 400px; height: 40px; min-height: 40px; justify-self: start;
  gap: 10px; padding: 0 12px; border: 1px solid #747775; border-radius: 10px; background: #fff; color: #1F1F1F;
  font-family: Roboto, Arial, sans-serif; font-size: 14px; font-weight: 500; letter-spacing: .25px; }
.auth-panel .google-button:hover { background: #F8F9FA; }
.auth-panel .google-button:disabled { opacity: .6; cursor: progress; }
.auth-panel .google-button img { width: 18px; height: 18px; flex: none; }
.auth-panel #continue-email,
.auth-panel #request-email-again { height: 40px; min-height: 40px; padding-block: 0; }
.practice-timer { min-width: 0; display: grid; gap: 9px; padding: clamp(13px, 2.7vw, 22px); border-radius: 15px; background: var(--dark); color: #fff; }
.practice-timer .eyebrow { color: var(--lime); }
.practice-timer .badge { background: #fff; color: var(--dark); }
.practice-clock { margin: 0; font: 850 clamp(2.9rem, 13vw, 5rem)/1 var(--display); letter-spacing: -.07em; font-variant-numeric: tabular-nums; }
.practice-next { color: #d5e7dc; font-size: .86rem; }
.practice-list { display: grid; gap: 6px; margin: 12px 0 0; padding: 0; list-style: none; }
.practice-list > li { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: start; gap: 6px 10px; padding: 9px; border: 1px solid var(--line); border-radius: 10px; }
.practice-list > li[aria-current="step"] { background: #eef3d9; border-color: #99ae68; }
.practice-list > li > div { min-width: 0; }
.practice-list p { color: var(--muted); font-size: .85rem; white-space: pre-line; }
.practice-order { font: 700 .77rem/1.5 ui-monospace, monospace; color: #466343; }
.practice-minutes { white-space: nowrap; font-size: .85rem; font-weight: 700; }
.practice-list .btn { padding-inline: 8px; }
@media (max-width: 730px) {
  html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
  .header-inner { min-height: 62px; padding: 8px 14px; flex-wrap: wrap; gap: 8px; }
  .brand { font-size: clamp(20px, 5.5vw, 24px); gap: 7px; }
  .auth-shell, .workspace { padding: 14px 14px 28px; }
  .auth-shell { grid-template-columns: 1fr; gap: 12px; }
  .intro-panel { min-height: unset; padding: 19px; border-radius: 18px; }
  .intro-panel h1 { margin: 10px 0; font-size: 1.8rem; }
  .intro-court { display: none; }
  .intro-panel p { font-size: .85rem; }
  .auth-panel { padding: 16px; }
  .site-footer { padding-inline: 15px; }
  .session-name { display: none; }
  input:not([type="checkbox"]):not([type="radio"]), select, textarea { font-size: 16px; }
  .practice-list .btn { grid-column: 2 / -1; justify-self: start; }
}
@media (pointer: coarse) {
  html, body, dialog { touch-action: pan-x pan-y pinch-zoom; }
}

/* ロゴ（ロゴ制作_追加指示書_v5、outputs/ロゴUI配置仕様_v1.md） */
.site-header .brand { gap: 0; line-height: 0; }
.brand-logo { display: block; height: 44px; width: auto; }
.brand-symbol { display: none; height: 32px; width: auto; }
.service-logo { display: block; height: 48px; width: auto; margin-bottom: 4px; }
/* ノッチ・ホームインジケーターを避け、拡大表示を妨げない。 */
.site-header { padding-top: env(safe-area-inset-top, 0px); }
.header-inner { padding-left: max(24px, env(safe-area-inset-left, 0px)); padding-right: max(24px, env(safe-area-inset-right, 0px)); }
.auth-shell, .workspace { padding-left: max(24px, env(safe-area-inset-left, 0px)); padding-right: max(24px, env(safe-area-inset-right, 0px)); }
.site-footer { padding-bottom: max(20px, env(safe-area-inset-bottom, 0px)); }
.brand { flex: none; }
.brand-logo, .brand-symbol, .service-logo { object-fit: contain; }
@media (max-width: 730px) {
  .brand-logo { height: 40px; }
  body.is-signed-in .brand-logo { display: none; }
  body.is-signed-in .brand-symbol { display: block; }
  .header-inner { padding-left: max(14px, env(safe-area-inset-left, 0px)); padding-right: max(14px, env(safe-area-inset-right, 0px)); }
  .auth-shell, .workspace { padding-left: max(14px, env(safe-area-inset-left, 0px)); padding-right: max(14px, env(safe-area-inset-right, 0px)); }
}
/* S1 通信断の帯（画面契約_v1 S1） */
.offline-banner { position: sticky; top: 0; z-index: 50; margin: 0; padding: 10px 16px; background: #172240; color: #fff; font-size: .875rem; font-weight: 700; }
.offline-banner::before { content: ''; display: inline-block; width: 8px; height: 8px; margin-right: 8px; border-radius: 50%; background: #F04A2E; vertical-align: middle; }
