/* 寝顔の無音カメラ（/negao-camera/）。暗い寝室で開いても眩しくないよう、操作の面は暗い地・控えめな琥珀色にする */
[hidden] { display: none !important; }
.nc-app {
  --nc-bg: #0f1218; --nc-bg2: #161b24; --nc-line: #262d3a; --nc-ink: #e6e0d6; --nc-soft: #9aa1ad; --nc-amber: #e3a457; --nc-amber-ink: #1a1206;
  background: var(--nc-bg); color: var(--nc-ink); border: 1px solid #000; padding: 22px 22px 20px; margin-bottom: 8px;
}
.nc-app a { color: var(--nc-amber); }
.nc-warn { display: flex; gap: 10px; align-items: flex-start; margin: 0 0 18px; padding: 10px 12px; border: 1px solid #5a4424; background: #1d1810; color: #f0d5ad; font-size: 14px; line-height: 1.6; }
.nc-warn::before { content: "!"; flex: 0 0 auto; width: 20px; height: 20px; border-radius: 50%; background: var(--nc-amber); color: var(--nc-amber-ink); font: 700 13px/20px var(--mono); text-align: center; margin-top: 1px; }

/* 起動前 */
.nc-idle { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 26px; align-items: center; }
.nc-art { position: relative; aspect-ratio: 4 / 3; background: radial-gradient(120% 90% at 18% 10%, #22304d 0%, #121827 55%, #0c1019 100%); border: 1px solid var(--nc-line); overflow: hidden; }
.nc-art svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.nc-art-tag { position: absolute; left: 12px; bottom: 10px; font: 500 11px/1 var(--mono); letter-spacing: .08em; color: var(--nc-soft); }
.nc-go-wrap h2 { margin: 0 0 6px; font-size: 20px; color: #fff; }
.nc-go-wrap p { margin: 0 0 16px; color: var(--nc-soft); font-size: 14px; line-height: 1.7; }
.nc-btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 0 22px; border: 1px solid var(--nc-amber); background: var(--nc-amber); color: var(--nc-amber-ink); font-family: inherit; font-size: 16px; font-weight: 700; line-height: 1.2; text-align: center; cursor: pointer; transition: transform .08s ease, opacity .15s; }
.nc-btn:active { transform: scale(.97); }
.nc-btn[disabled] { opacity: .45; cursor: default; }
.nc-btn.sub { background: transparent; color: var(--nc-ink); border-color: #3a4352; font-weight: 500; font-size: 15px; }
.nc-btn.sub:hover { border-color: var(--nc-amber); color: #fff; }
.nc-go-row { display: flex; flex-wrap: wrap; gap: 10px; }
.nc-go-row .nc-btn:first-child { flex: 1 1 220px; }
.nc-facts { list-style: none; margin: 18px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 14px; font-size: 13px; color: var(--nc-soft); }
.nc-facts li { padding-left: 16px; position: relative; }
.nc-facts li::before { content: ""; position: absolute; left: 0; top: .62em; width: 7px; height: 7px; border-radius: 50%; background: var(--nc-amber); opacity: .8; }
.nc-err { margin: 14px 0 0; padding: 10px 12px; border-left: 3px solid #e06c5a; background: #241515; color: #f4c7bf; font-size: 14px; line-height: 1.6; }

/* 撮影中（全画面） */
html.nc-lock, html.nc-lock body { overflow: hidden; }
html.nc-lock site-concierge { display: none !important; }   /* 撮影中は相談の吹き出しを重ねない */
.nc-live { position: fixed; inset: 0; z-index: 2147483000; background: #000; color: var(--nc-ink); display: grid; grid-template-rows: auto minmax(0, 1fr) auto; }
.nc-live-top { display: flex; align-items: center; gap: 10px; padding: calc(env(safe-area-inset-top, 0px) + 10px) 14px 8px; }
.nc-live-top .nc-mini { flex: 1 1 auto; min-width: 0; font-size: 12px; line-height: 1.5; color: #c9b597; }
.nc-flag { flex: 0 0 auto; white-space: nowrap; font: 500 11px/1 var(--mono); letter-spacing: .06em; color: var(--nc-amber-ink); background: var(--nc-amber); padding: 5px 7px; }
.nc-x { flex: 0 0 auto; width: 44px; height: 44px; border: 1px solid #333a46; background: #0b0d11; color: #e6e0d6; font-size: 22px; line-height: 1; cursor: pointer; }
.nc-view { position: relative; min-height: 0; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.nc-view video, .nc-view canvas { width: 100%; height: 100%; object-fit: contain; display: block; }
.nc-corners { position: absolute; inset: 14px; pointer-events: none; opacity: .5;
  background:
    linear-gradient(#fff, #fff) left top / 22px 1px no-repeat, linear-gradient(#fff, #fff) left top / 1px 22px no-repeat,
    linear-gradient(#fff, #fff) right top / 22px 1px no-repeat, linear-gradient(#fff, #fff) right top / 1px 22px no-repeat,
    linear-gradient(#fff, #fff) left bottom / 22px 1px no-repeat, linear-gradient(#fff, #fff) left bottom / 1px 22px no-repeat,
    linear-gradient(#fff, #fff) right bottom / 22px 1px no-repeat, linear-gradient(#fff, #fff) right bottom / 1px 22px no-repeat; }
.is-shooting .nc-corners { opacity: 1; }
.is-shooting .nc-view video, .is-shooting .nc-view canvas { opacity: .82; }   /* 取り込み中は映像を少し沈め、押したことを画面全体でも伝える */
.nc-live-bottom { display: grid; justify-items: center; gap: 10px; padding: 10px 16px calc(env(safe-area-inset-bottom, 0px) + 18px); }
.nc-hint { margin: 0; min-height: 1.6em; font-size: 14px; color: #d8d0c3; text-align: center; }
.nc-dots { display: flex; gap: 8px; }
.nc-dots span { width: 9px; height: 9px; border-radius: 50%; border: 1px solid #59606c; transition: background-color .08s, border-color .08s, transform .12s; }
.nc-dots span.now { border-color: var(--nc-amber); transform: scale(1.2); }
.nc-dots span.on { background: #d8d0c3; border-color: #d8d0c3; }
.nc-dots span.best { background: var(--nc-amber); border-color: var(--nc-amber); transform: scale(1.35); }
.nc-shutter { --p: 0; width: 76px; height: 76px; border-radius: 50%; border: 4px solid #e6e0d6; background: transparent; padding: 0; position: relative; cursor: pointer; touch-action: manipulation; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
.nc-shutter::after { content: ""; position: absolute; inset: 6px; border-radius: 50%; background: #e6e0d6; transition: transform .08s ease, background-color .08s; }
.nc-shutter.is-down::after, .is-shooting .nc-shutter::after { transform: scale(.82); background: var(--nc-amber); }
/* 取り込み中はシャッターの縁を進み具合の輪にする（--p = 取り込んだ割合）。再押下は app.js が受け付けない */
.is-shooting .nc-shutter { border-color: transparent; cursor: progress; background: conic-gradient(var(--nc-amber) calc(var(--p) * 1turn), #3a4352 0); }
.is-shooting .nc-shutter::after { transform: scale(.7); background: #1a1d24; box-shadow: inset 0 0 0 3px var(--nc-amber); }
.nc-shutter[disabled] { opacity: .35; cursor: default; }

/* 結果（全画面の中で、映像の代わりに出す面。撮影から保存まで暗いまま・操作は下に揃える） */
.nc-live.is-review .nc-view, .nc-live.is-review .nc-live-bottom { display: none; }
.nc-live.is-review { grid-template-rows: auto minmax(0, 1fr); }
.nc-result { min-height: 0; display: grid; grid-template-rows: auto minmax(120px, 1fr) auto auto auto auto; width: 100%; max-width: 980px; margin: 0 auto; padding: 0 14px calc(env(safe-area-inset-bottom, 0px) + 14px); outline: none; }
.nc-result-h { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 2px 16px; margin-bottom: 8px; }
.nc-result-h b { font-size: 16px; color: #fff; }
.nc-result-h span { font-size: 12px; color: var(--nc-soft); }
.nc-pick { position: relative; min-height: 0; background: #000; }
.nc-pick-in { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.nc-pick-c { display: block; max-width: 100%; max-height: 100%; width: auto; height: auto; }
.nc-badge { background: var(--nc-amber); color: var(--nc-amber-ink); font-size: 12px; font-weight: 700; line-height: 1; padding: 6px 8px; z-index: 1; }
.nc-pick-line { display: flex; align-items: center; gap: 8px; margin: 8px 0 0; }
.nc-pick-line .nc-badge { flex: 0 0 auto; white-space: nowrap; padding: 4px 6px; font-size: 11px; }
.nc-pick-meta { font-size: 12px; line-height: 1.4; color: var(--nc-soft); font-family: var(--mono); }
.nc-thumbs { list-style: none; margin: 10px 0 0; padding: 0; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.nc-thumbs button { position: relative; display: block; width: 100%; padding: 0; border: 1px solid var(--nc-line); background: #000; color: inherit; cursor: pointer; text-align: left; transition: border-color .12s, transform .08s; }
.nc-thumbs button:hover { border-color: #5a6372; }
.nc-thumbs button:active { transform: scale(.97); }
.nc-thumbs button.is-best { border-color: var(--nc-amber); }
.nc-thumbs button .nc-badge { position: absolute; left: 3px; top: 3px; font-size: 10px; padding: 3px 4px; }
.nc-thumbs canvas { display: block; width: 100%; height: auto; }
.nc-cap { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 0 4px; padding: 4px 5px 5px; background: var(--nc-bg2); font-size: 11px; line-height: 1.3; }
.nc-cap b { font-weight: 500; color: var(--nc-soft); white-space: nowrap; }
.nc-cap em { font: 500 12px/1.3 var(--mono); font-style: normal; color: var(--nc-ink); }
.nc-bar { display: block; flex-basis: 100%; height: 3px; margin-top: 3px; background: #252b36; }
.nc-bar span { display: block; height: 100%; background: #8c94a2; }
.is-best .nc-bar span { background: var(--nc-amber); }
.nc-actions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 12px; }
.nc-actions .nc-btn { padding: 0 8px; }
.nc-fine { margin: 8px 0 0; font-size: 12px; line-height: 1.6; color: var(--nc-soft); }
.nc-all { margin: 14px 0 0; font-size: 14px; }
.nc-all a { color: var(--accent-dark); text-underline-offset: 3px; }
.nc-tell-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--nc-line); }
.nc-tell-row p { margin: 0; font-size: 13px; color: var(--nc-soft); flex: 1 1 260px; }
.nc-tell-msg { flex-basis: 100%; font-size: 13px; color: #f0d5ad; word-break: break-all; }
.nc-tell-msg:empty { display: none; }

@media (max-width: 760px) {
  .nc-app { padding: 16px 14px; margin-left: -4px; margin-right: -4px; }
  .nc-idle { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .nc-art { order: 2; aspect-ratio: 16 / 9; }   /* 狭い画面では起動ボタンを先に見せる */
  .nc-art svg { inset: -12% 0 auto; height: 124%; }
  .nc-cap b { display: none; }          /* 狭い画面では枚数を読み上げ名（aria-label）に任せ、数字と棒だけ */
  .nc-cap { justify-content: center; padding: 3px 3px 4px; }
  .nc-thumbs button .nc-badge { display: none; }   /* 幅が44px前後で入らない。おすすめは琥珀の枠と棒・数字100で示す */
  .nc-actions .nc-btn { font-size: 14px; min-height: 46px; }
  .nc-facts { grid-template-columns: minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  .nc-btn, .nc-dots span, .nc-shutter::after, .nc-thumbs button { transition: none; }
}
