/*!*****************************************************************************************************************************************************************************************************************************************************************!*\
  !*** css ./node_modules/next/dist/build/webpack/loaders/css-loader/src/index.js??ruleSet[1].rules[14].oneOf[10].use[2]!./node_modules/next/dist/build/webpack/loaders/postcss-loader/src/index.js??ruleSet[1].rules[14].oneOf[10].use[3]!./src/app/globals.css ***!
  \*****************************************************************************************************************************************************************************************************************************************************************/
:root {
  --bg: #000000;
  --surface: rgba(0, 0, 0, 0.75);
  --text: #ffffff;
  --text-muted: rgba(255, 255, 255, 0.78);
  --gold: #f5d061;
  --gold-deep: #c6a34f;
  --danger: #ef4444;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  font-family: "Noto Sans JP", "Hiragino Sans", sans-serif;
  color: var(--text);
}

body {
  position: relative;
  min-height: 100vh;
  background: #000;
}

/*
  backend/resources/css/liff.css の黒背景+上部ビジュアルを参考にした表現。
  画像依存を避けるためグラデーションで近い雰囲気を再現する。
*/
body::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1100px;
  pointer-events: none;
  z-index: 0;
  background-image: -webkit-image-set(
    url("/img/kampai-cheers-bg.webp") type("image/webp"),
    url("/img/kampai-cheers-bg.jpg") type("image/jpeg")
  );
  background-image: image-set(
    url("/img/kampai-cheers-bg.webp") type("image/webp"),
    url("/img/kampai-cheers-bg.jpg") type("image/jpeg")
  );
  background-position: center top;
  background-size: contain;
  background-repeat: no-repeat;
}

/*
  旧画面の「きらめき」演出を軽く再現するためのオーバーレイ。
  背景画像が未配置でも破綻しないよう、単体でも成立するようにしている。
*/
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(circle at 18% 24%, rgba(245, 208, 97, 0.26) 0 2px, transparent 3px),
    radial-gradient(circle at 72% 18%, rgba(245, 208, 97, 0.22) 0 2px, transparent 3px),
    radial-gradient(circle at 48% 36%, rgba(255, 235, 170, 0.22) 0 2px, transparent 3px),
    radial-gradient(circle at 84% 44%, rgba(245, 208, 97, 0.18) 0 2px, transparent 3px),
    radial-gradient(circle at 12% 62%, rgba(255, 235, 170, 0.18) 0 2px, transparent 3px),
    radial-gradient(circle at 56% 12%, rgba(255, 235, 170, 0.16) 0 2px, transparent 3px);
  background-size: 100% 100%;
}

main {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  position: relative;
  z-index: 1;
}

.container {
  width: 100%;
  max-width: 28rem;
  margin: 0 auto;
}

.kp-card,
.card {
  background: var(--surface);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border: 2px solid rgba(245, 208, 97, 0.6);
  border-radius: 24px;
  padding: 30px 22px;
  box-shadow: 0 0 30px rgba(245, 208, 97, 0.25), inset 0 0 30px rgba(0, 0, 0, 0.45);
  text-align: center;
}

.liff-page {
  position: relative;
  z-index: 1;
}

.title {
  margin: 0 0 8px;
  color: var(--gold);
  font-size: 1.45rem;
  letter-spacing: 0.04em;
}

.muted {
  color: var(--text-muted);
  margin: 0 0 20px;
  font-size: 0.95rem;
  line-height: 1.65;
}

.button {
  width: 100%;
  border: 0;
  border-radius: 24px;
  padding: 12px 16px;
  font-size: 0.96rem;
  font-weight: 700;
  cursor: pointer;
}

.button-primary {
  background: linear-gradient(to bottom, #fdb931, var(--gold-deep));
  color: #222;
}

.alert {
  margin-top: 16px;
  border-radius: 10px;
  padding: 12px;
  font-size: 0.95rem;
}

.alert-error {
  border: 1px solid rgba(239, 68, 68, 0.5);
  background: rgba(239, 68, 68, 0.15);
  color: #fecaca;
}

.kv {
  display: grid;
  grid-template-columns: 120px 1fr;
  grid-gap: 8px;
  gap: 8px;
  margin: 8px 0;
  text-align: left;
}

.kv strong {
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.86rem;
}

.kv span {
  color: #fff;
  font-size: 0.9rem;
  word-break: break-all;
}

.profile-head {
  display: flex;
  justify-content: center;
  margin: 4px 0 18px;
}

.profile-image,
.profile-fallback {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  border: 2px solid rgba(245, 208, 97, 0.75);
  box-shadow: 0 0 16px rgba(245, 208, 97, 0.28);
}

.profile-image {
  object-fit: cover;
}

.profile-fallback {
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 1.5rem;
  color: #222;
  background: linear-gradient(135deg, #f5d061 0%, #d4af37 100%);
}

.profile-kv {
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 8px;
}

.top-main {
  align-items: flex-start;
  padding-top: 72px;
  padding-bottom: 120px;
}

.top-container {
  max-width: 330px;
}

.top-card {
  padding: 24px 20px 26px;
  border-radius: 28px;
  background:
    radial-gradient(circle at 50% 18%, rgba(245, 208, 97, 0.14), rgba(0, 0, 0, 0.72) 58%),
    rgba(0, 0, 0, 0.74);
}

.top-title {
  margin: 0 0 14px;
  color: #fff;
  font-size: 2.2rem;
  letter-spacing: 0.06em;
  font-weight: 700;
  line-height: 1.05;
  text-shadow: 0 0 14px rgba(245, 208, 97, 0.24);
}

.top-name {
  margin: 6px 0 4px;
  font-size: 1.95rem;
  color: #fff;
  font-weight: 700;
}

.top-sub-name {
  margin: 0;
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.8);
  font-weight: 600;
}

.top-hobby {
  margin: 18px 0 0;
  font-size: 1rem;
  color: var(--gold);
  font-weight: 700;
}

.top-load-error {
  margin: 12px 0 0;
  font-size: 0.78rem;
  color: rgba(255, 220, 220, 0.92);
}

.top-profile-incomplete {
  margin: 14px 0 0;
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid rgba(239, 68, 68, 0.5);
  background: rgba(239, 68, 68, 0.15);
  color: #fecaca;
  font-size: 0.88rem;
  font-weight: 600;
}

.top-work-places {
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: left;
}

.top-work-place-item {
  padding: 8px 12px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.9rem;
}

.native-loading {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  position: relative;
  z-index: 1;
}

.liff-bottom-menu {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  height: 74px;
  padding: 0 8px;
  background:
    linear-gradient(180deg, rgba(18, 18, 34, 0.92) 0%, rgba(8, 8, 18, 0.98) 100%);
  -webkit-backdrop-filter: blur(12px);
          backdrop-filter: blur(12px);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: space-around;
  z-index: 20;
}

.liff-menu-item {
  width: 64px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  border: none;
  background: transparent;
  color: rgba(255, 255, 255, 0.4);
  font-size: 9px;
  letter-spacing: 0.04em;
  font-weight: 700;
  padding: 0;
}

.liff-menu-item.active {
  color: var(--gold);
  text-shadow: 0 0 8px rgba(245, 208, 97, 0.4);
}

.liff-menu-item:disabled {
  opacity: 0.45;
}

.liff-menu-item i {
  font-size: 18px;
  line-height: 1;
}

.liff-menu-center {
  border: none;
  background: transparent;
  margin-top: -22px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  padding: 0;
}

.liff-menu-center-btn {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #f5d061, #d4af37);
  border: 3px solid #1a1a2e;
  box-shadow:
    0 6px 18px rgba(245, 208, 97, 0.48),
    inset 0 1px 0 rgba(255, 255, 255, 0.45);
}

.liff-menu-center-btn i {
  color: #fff;
  font-size: 22px;
  line-height: 1;
}

.liff-menu-center-label {
  font-size: 9px;
  letter-spacing: 0.05em;
  color: var(--gold);
  font-weight: 800;
}

.liff-menu-center.active .liff-menu-center-btn {
  box-shadow:
    0 8px 20px rgba(245, 208, 97, 0.6),
    inset 0 1px 0 rgba(255, 255, 255, 0.45);
}

.liff-bottom-spacer {
  height: 84px;
}

.kampai-main {
  padding-top: 70px;
}

.kampai-card {
  padding: 24px 20px 22px;
}

.kampai-title {
  margin-bottom: 10px;
  font-size: 2.1rem;
}

.qr-caption {
  margin: 0 0 14px;
  color: rgba(255, 255, 255, 0.84);
  font-size: 0.93rem;
  line-height: 1.5;
}

.liff-qr-frame {
  width: 100%;
  max-width: 286px;
  margin: 0 auto 16px;
  padding: 10px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 0 20px rgba(245, 208, 97, 0.2);
}

.liff-qr-image {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 6px;
}

.kampai-warning {
  margin: 0 0 14px;
  color: rgba(255, 230, 230, 0.9);
  font-size: 0.84rem;
}

.kampai-place-button {
  max-width: 256px;
  margin: 0 auto;
  background: linear-gradient(to bottom, #f5d061, #d4af37);
  color: #2a1f0a;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

/* KampaiQrPage: session state UI */

.kampai-session-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 24px 0;
}

.kampai-session-status {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.08);
  margin: 10px 0;
}

.kampai-session-status.waiting .kampai-session-status-dot {
  background: #4ade80;
  box-shadow: 0 0 6px rgba(74, 222, 128, 0.7);
}

.kampai-session-status.locked .kampai-session-status-dot {
  background: #facc15;
  box-shadow: 0 0 6px rgba(250, 204, 21, 0.7);
}

.kampai-session-status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  flex-shrink: 0;
  animation: statusPulse 1.8s ease-in-out infinite;
}

@keyframes statusPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.kampai-session-status-text {
  color: var(--text);
}

.kampai-session-hint {
  margin: 4px 0 14px;
  font-size: 0.84rem;
  color: var(--text-muted);
  text-align: center;
}

.kampai-session-cancel-button {
  max-width: 256px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: var(--text-muted);
  font-size: 0.88rem;
}

.kampai-session-cancel-button:hover {
  background: rgba(255, 255, 255, 0.16);
}

.kampai-session-complete {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 16px 0;
}

.kampai-session-complete-title {
  margin: 0;
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--gold);
}

/* ExchangePage: session-locked (new flow) */

.exchange-session-locked {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
}

.exchange-session-locked-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  border-radius: 999px;
  background: rgba(74, 222, 128, 0.12);
  border: 1px solid rgba(74, 222, 128, 0.3);
  font-size: 0.92rem;
  font-weight: 700;
  color: #4ade80;
  margin: 6px 0;
}

.exchange-session-locked-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 6px rgba(74, 222, 128, 0.7);
  flex-shrink: 0;
  animation: statusPulse 1.8s ease-in-out infinite;
}

.exchange-session-locked-message {
  margin: 0;
  font-size: 0.95rem;
  color: var(--text-muted);
}

.exchange-session-confirm-button {
  width: 100%;
  max-width: 280px;
  margin: 8px auto 0;
  font-size: 1.1rem;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.exchange-session-back-button {
  max-width: 280px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: var(--text-muted);
  font-size: 0.88rem;
}

.exchange-session-back-button:hover {
  background: rgba(255, 255, 255, 0.12);
}

/* Place Select Page */

.place-select-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 20px 20px 24px;
}

.place-select-header {
  display: flex;
  align-items: center;
  gap: 10px;
}

.place-back-button {
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.85);
  font-size: 1.1rem;
  cursor: pointer;
  padding: 4px 6px;
  flex-shrink: 0;
  line-height: 1;
}

.place-select-title {
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
}

.place-location-button {
  width: 100%;
  background: linear-gradient(to bottom, #f5d061, #d4af37);
  color: #2a1f0a;
  border-radius: 999px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 16px;
}

.place-tabs {
  display: flex;
  border-bottom: 1px solid rgba(255, 255, 255, 0.18);
}

.place-tab-item {
  flex: 1 1;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.9rem;
  padding: 8px 0;
  cursor: pointer;
  margin-bottom: -1px;
  transition: color 0.15s, border-color 0.15s;
}

.place-tab-item.active {
  color: #f5d061;
  border-bottom-color: #f5d061;
  font-weight: 700;
}

.place-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-height: 72px;
}

.place-list-item {
  width: 100%;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  padding: 10px 14px;
  cursor: pointer;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 2px;
  transition: background 0.15s, border-color 0.15s;
}

.place-list-item:active {
  background: rgba(245, 208, 97, 0.12);
  border-color: rgba(245, 208, 97, 0.35);
}

.place-list-name {
  color: #fff;
  font-size: 0.95rem;
  font-weight: 600;
}

.place-list-address {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.78rem;
}

.place-list-empty {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.88rem;
  text-align: center;
  margin: 16px 0;
}

.place-list-error {
  background: rgba(200, 50, 50, 0.18);
  border: 1px solid rgba(200, 50, 50, 0.4);
  border-radius: 10px;
  color: #fecaca;
  font-size: 0.9rem;
  padding: 12px;
  text-align: center;
}

.place-list-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 4px;
}

.place-list-distance {
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.75rem;
}

.place-list-action {
  color: #f5d061;
  font-size: 0.8rem;
  font-weight: 600;
}

.place-skip-button {
  width: 100%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.65);
  padding: 12px 16px;
  font-size: 0.9rem;
}

.exchange-main {
  padding-top: 84px;
}

.exchange-card {
  padding: 24px 20px;
}

.exchange-processing {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.exchange-spinner {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 4px solid rgba(245, 208, 97, 0.3);
  border-top-color: var(--gold);
  animation: spin 0.9s linear infinite;
}

.exchange-title {
  margin: 0;
  font-size: 1.8rem;
  color: #fff;
  letter-spacing: 0.04em;
}

.exchange-message {
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
}

.exchange-error {
  margin: 0 0 8px;
  color: #fecaca;
  font-size: 0.94rem;
}

.exchange-success {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.exchange-success-message {
  margin: 0;
  color: #86efac;
  font-weight: 700;
}

.exchange-partner {
  margin: 0;
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.9);
}

.exchange-partner-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  width: 100%;
  padding: 14px 12px;
  background: rgba(0, 0, 0, 0.36);
  border: 1px solid rgba(245, 208, 97, 0.35);
  border-radius: 12px;
}

.exchange-partner-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(245, 208, 97, 0.55);
}

.exchange-partner-avatar-placeholder {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: rgba(245, 208, 97, 0.15);
  border: 2px solid rgba(245, 208, 97, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  color: #f5d061;
  font-weight: 700;
}

.exchange-partner-name {
  margin: 0;
  color: #fff;
  font-weight: 700;
  font-size: 1.05rem;
}

.exchange-partner-label {
  margin: 0;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.8rem;
}

.exchange-summary {
  width: 100%;
  border: 1px solid rgba(245, 208, 97, 0.35);
  border-radius: 12px;
  padding: 12px;
  text-align: left;
  background: rgba(0, 0, 0, 0.36);
}

.exchange-summary p {
  margin: 0 0 6px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.9rem;
}

.exchange-summary p:last-child {
  margin-bottom: 0;
}

.exchange-motivation {
  margin: 2px 0;
  color: rgba(255, 255, 255, 0.84);
  font-size: 0.88rem;
  line-height: 1.45;
}

.exchange-title-badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
}

.exchange-badge {
  padding: 4px 8px;
  border-radius: 999px;
  border: 1px solid rgba(245, 208, 97, 0.55);
  background: rgba(245, 208, 97, 0.15);
  color: #f5d061;
  font-size: 0.75rem;
  font-weight: 700;
}

.exchange-previous-card {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 12px;
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.05);
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.exchange-previous-title {
  margin: 0;
  font-size: 0.75rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.45);
  letter-spacing: 0.06em;
}

.exchange-previous-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.exchange-previous-label {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.82rem;
  flex-shrink: 0;
}

.exchange-previous-value {
  color: #fff;
  font-size: 0.88rem;
  font-weight: 600;
  text-align: right;
}

.exchange-suggest-card {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 12px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.04);
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.exchange-suggest-loading {
  align-items: center;
  padding: 10px 14px;
}

.exchange-suggest-loading-text {
  margin: 0;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.4);
}

.exchange-suggest-title {
  margin: 0;
  font-size: 0.82rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.72);
}

.exchange-suggest-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.exchange-suggest-chip {
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(245, 208, 97, 0.55);
  background: rgba(245, 208, 97, 0.12);
  color: #f5d061;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
}

.exchange-suggest-chip-alt {
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.07);
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.82rem;
  cursor: pointer;
}

.exchange-suggest-chip-dismiss {
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: transparent;
  color: rgba(255, 255, 255, 0.4);
  font-size: 0.82rem;
  cursor: pointer;
}

.exchange-suggest-registered {
  align-items: flex-start;
  padding: 10px 14px;
}

.exchange-suggest-registered-text {
  margin: 0;
  font-size: 0.86rem;
  font-weight: 700;
  color: #86efac;
}

.exchange-debug {
  margin: 0;
  color: rgba(255, 255, 255, 0.62);
  font-size: 0.72rem;
  word-break: break-all;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.native-loading-card {
  width: 100%;
  max-width: 360px;
  padding: 28px 24px;
  border-radius: 20px;
  border: 1px solid rgba(245, 208, 97, 0.45);
  background: rgba(0, 0, 0, 0.78);
  box-shadow: 0 12px 40px rgba(2, 6, 23, 0.45);
  text-align: center;
}

.native-loading-logo {
  width: 64px;
  height: 64px;
  margin: 0 auto 14px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 1.4rem;
  color: #222;
  background: linear-gradient(135deg, #f5d061 0%, #d4af37 100%);
  animation: nativePulse 1.6s ease-in-out infinite;
}

.native-loading-title {
  margin: 0;
  color: var(--gold);
  font-size: 1.2rem;
  font-weight: 700;
}

.native-loading-message {
  margin: 8px 0 18px;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.native-loading-track {
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.25);
  overflow: hidden;
}

.native-loading-bar {
  display: block;
  width: 35%;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #f5d061 0%, #d4af37 100%);
  animation: nativeSlide 1.2s ease-in-out infinite;
}

@keyframes nativePulse {
  0%,
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(245, 208, 97, 0.35);
  }
  50% {
    transform: scale(1.06);
    box-shadow: 0 0 0 12px rgba(245, 208, 97, 0);
  }
}

@keyframes nativeSlide {
  0% {
    transform: translateX(-120%);
  }
  100% {
    transform: translateX(320%);
  }
}

/* ========== Card List ========== */

.card-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.card-list-row {
  display: flex;
  align-items: center;
  background: rgba(0, 0, 0, 0.55);
  border: 1px solid rgba(245, 208, 97, 0.3);
  border-radius: 14px;
  overflow: hidden;
}

.card-list-main {
  flex: 1 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
}

.card-list-main:active {
  background: rgba(245, 208, 97, 0.06);
}

.card-list-avatar {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
}

.card-list-avatar-img {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(245, 208, 97, 0.4);
}

.card-list-avatar-placeholder {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: rgba(245, 208, 97, 0.18);
  border: 2px solid rgba(245, 208, 97, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold);
  font-size: 1.4rem;
  font-weight: 700;
}

.card-list-info {
  flex: 1 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.card-list-name {
  margin: 0;
  color: #fff;
  font-size: 1rem;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-list-date,
.card-list-place {
  margin: 0;
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.78rem;
  display: flex;
  align-items: center;
  gap: 5px;
}

.card-list-icon {
  color: rgba(245, 208, 97, 0.75);
  font-size: 0.75rem;
  flex-shrink: 0;
}

.card-list-actions {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0 14px 0 0;
  gap: 8px;
}

.card-list-edit-btn {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.85rem;
  line-height: 1;
}

.card-list-edit-btn:hover {
  color: rgba(255, 255, 255, 0.85);
}

.card-list-star-btn {
  background: none;
  border: none;
  padding: 10px;
  cursor: pointer;
  line-height: 1;
}

.card-list-star {
  font-size: 1.1rem;
  color: rgba(212, 175, 55, 0.4);
}

.card-list-star--active {
  color: var(--gold);
}

/* ========== Card Detail ========== */

.card-detail-card {
  padding: 20px 16px 24px;
}

.card-detail-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}

.card-detail-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.card-detail-avatar-wrap {
  margin-top: 4px;
}

.card-detail-avatar-img {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid rgba(245, 208, 97, 0.5);
}

.card-detail-avatar-placeholder {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: rgba(245, 208, 97, 0.18);
  border: 3px solid rgba(245, 208, 97, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold);
  font-size: 2rem;
  font-weight: 700;
}

.card-detail-name {
  margin: 0;
  color: #fff;
  font-size: 1.3rem;
  font-weight: 700;
  text-align: center;
}

.card-detail-sub-name {
  margin: -8px 0 0;
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.88rem;
  text-align: center;
}

.card-detail-section {
  width: 100%;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(245, 208, 97, 0.2);
  border-radius: 12px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.card-detail-section-title {
  margin: 0 0 4px;
  color: var(--gold);
  font-size: 0.85rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
}

.card-detail-icon {
  font-size: 0.8rem;
}

.card-detail-row {
  display: flex;
  align-items: center;
  gap: 8px;
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.88rem;
}

.card-detail-row-icon {
  color: rgba(245, 208, 97, 0.7);
  font-size: 0.78rem;
  flex-shrink: 0;
  width: 14px;
  text-align: center;
}

.card-detail-text {
  margin: 0;
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.9rem;
  line-height: 1.6;
}

.card-detail-work-places {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.card-detail-work-place-item {
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.9rem;
  padding-left: 12px;
  position: relative;
}

.card-detail-work-place-item::before {
  content: "·";
  position: absolute;
  left: 2px;
  color: var(--gold);
}

/* =============================================
   名刺詳細 プロフィールカード
   ============================================= */

.card-detail-profile-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 16px 0 8px;
  gap: 6px;
}

.card-detail-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.card-detail-subtitle {
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.5);
  margin: 0;
}

.card-detail-edit-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--gold);
  padding: 4px;
  font-size: 0.85rem;
  line-height: 1;
}

/* =============================================
   名前編集モーダル
   ============================================= */

.card-detail-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
}

.card-detail-modal {
  background: #1a1a1a;
  border: 1px solid var(--gold);
  border-radius: 12px;
  padding: 24px;
  width: 80%;
  max-width: 360px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.card-detail-modal-title {
  margin: 0;
  font-size: 1rem;
  font-weight: bold;
  color: var(--gold);
}

.card-detail-modal-input {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  color: #fff;
  padding: 10px 12px;
  font-size: 0.95rem;
  width: 100%;
}

.card-detail-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
}

.card-detail-modal-cancel {
  background: none;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.7);
  padding: 8px 16px;
  cursor: pointer;
  font-size: 0.9rem;
}

.card-detail-modal-save {
  background: var(--gold);
  border: none;
  border-radius: 8px;
  color: #000;
  padding: 8px 16px;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: bold;
}

.card-detail-modal-save:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* =============================================
   AIサマリーカード
   ============================================= */

.ai-summary-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(245, 208, 97, 0.25);
  border-radius: 12px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ai-summary-tabs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.ai-summary-tab {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 20px;
  color: rgba(255, 255, 255, 0.7);
  padding: 6px 12px;
  cursor: pointer;
  font-size: 0.78rem;
  transition: background 0.2s, border-color 0.2s;
}

.ai-summary-tab--active {
  background: var(--gold);
  border-color: var(--gold);
  color: #000;
  font-weight: bold;
}

.ai-summary-tab--locked {
  opacity: 0.4;
  cursor: not-allowed;
}

.ai-summary-content {
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.88rem;
  line-height: 1.65;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ai-summary-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.ai-summary-badge {
  background: rgba(245, 208, 97, 0.15);
  border: 1px solid rgba(245, 208, 97, 0.35);
  border-radius: 16px;
  color: var(--gold);
  font-size: 0.78rem;
  padding: 4px 10px;
}

.ai-summary-notes {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.82rem;
  margin: 0;
}

.ai-summary-upgrade {
  display: block;
  text-align: center;
  color: var(--gold);
  font-size: 0.8rem;
  text-decoration: underline;
  padding: 4px 0;
}

.ai-summary-schedule {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.8rem;
  margin: 0;
}

/* =============================================
   乾杯履歴ボタン
   ============================================= */

.card-exchanges-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  background: rgba(245, 208, 97, 0.1);
  border: 1px solid rgba(245, 208, 97, 0.35);
  border-radius: 10px;
  color: var(--gold);
  padding: 12px 16px;
  cursor: pointer;
  font-size: 0.92rem;
  font-weight: bold;
  gap: 8px;
}

/* =============================================
   乾杯履歴タイムライン
   ============================================= */

.exchanges-timeline {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.exchanges-timeline-item {
  display: flex;
  gap: 12px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
}

.exchanges-avatar-wrap {
  flex-shrink: 0;
}

.exchanges-avatar-img {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
}

.exchanges-item-body {
  flex: 1 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.exchanges-partner-name {
  margin: 0;
  font-size: 0.95rem;
  font-weight: bold;
  color: #fff;
}

.exchanges-date {
  margin: 0;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.5);
}

.exchanges-place {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.75);
}

.exchanges-place-input {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 6px;
  color: #fff;
  padding: 4px 8px;
  font-size: 0.85rem;
}

.exchanges-type {
  margin: 0;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.45);
}

.exchanges-timeline-item--store-login {
  opacity: 0.75;
}

.exchanges-store-login {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  color: #63b3ed;
}

.exchanges-memo {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.exchanges-memo-body {
  margin: 0;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.8);
  white-space: pre-wrap;
}

.exchanges-memo-actions {
  display: flex;
  gap: 8px;
}

.exchanges-memo-textarea {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 6px;
  color: #fff;
  padding: 8px;
  font-size: 0.85rem;
  resize: vertical;
  min-height: 60px;
  width: 100%;
}

.exchanges-memo-add-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: 1px dashed rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.45);
  cursor: pointer;
  font-size: 0.8rem;
  padding: 6px 10px;
}

/* ─── TOPページ 活動履歴 ─── */

.top-history {
  margin-top: 16px;
}

.top-history-title {
  margin: 0 0 12px;
  font-size: 0.85rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.top-history-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.top-history-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
}

.top-history-icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
}

.top-history-icon--exchange {
  background: rgba(245, 208, 97, 0.15);
  color: var(--gold);
}

.top-history-icon--store {
  background: rgba(99, 179, 237, 0.15);
  color: #63b3ed;
}

.top-history-body {
  flex: 1 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.top-history-label {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 600;
  color: #fff;
}

.top-history-place {
  margin: 0;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.55);
  display: flex;
  align-items: center;
  gap: 4px;
}

.top-history-date {
  margin: 0;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.4);
}

.top-history-partner-login {
  margin: 0;
  font-size: 0.75rem;
  color: #63b3ed;
  display: flex;
  align-items: center;
  gap: 4px;
}

/* ─── 店ログイン ─── */

.store-login-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 20px;
}

.store-login-done-icon {
  font-size: 3rem;
  margin: 0 0 12px;
}

.store-login-done-text {
  font-size: 1rem;
  color: var(--text-muted);
  margin: 0;
}

.store-login-done-text strong {
  color: var(--gold);
}

/* ─── 設定ページ ─── */

.settings-page {
  text-align: left;
}

.settings-sections {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 16px;
}

.settings-section {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(245, 208, 97, 0.25);
  border-radius: 14px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.settings-section-title {
  margin: 0 0 4px;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--gold);
  display: flex;
  align-items: center;
  gap: 8px;
}

.settings-label {
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.85);
}

.settings-toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.settings-toggle {
  position: relative;
  width: 44px;
  height: 24px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.2);
  border: none;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.2s;
  padding: 0;
}

.settings-toggle--on {
  background: var(--gold-deep);
}

.settings-toggle-knob {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  transition: transform 0.2s;
}

.settings-toggle--on .settings-toggle-knob {
  transform: translateX(20px);
}

.settings-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.settings-radio-group {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.settings-radio-item {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 20px;
  color: rgba(255, 255, 255, 0.7);
  cursor: pointer;
  font-size: 0.8rem;
  padding: 5px 12px;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.settings-radio-item--active {
  background: rgba(245, 208, 97, 0.2);
  border-color: var(--gold);
  color: var(--gold);
}

.settings-save-row {
  display: flex;
  justify-content: flex-end;
  margin-top: 4px;
}

.settings-save-btn {
  background: linear-gradient(to bottom, #fdb931, var(--gold-deep));
  border: none;
  border-radius: 20px;
  color: #222;
  cursor: pointer;
  font-size: 0.88rem;
  font-weight: 700;
  padding: 8px 24px;
}

.settings-save-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.settings-delete-btn {
  background: rgba(255, 80, 80, 0.12);
  border: 1px solid rgba(255, 80, 80, 0.45);
  border-radius: 20px;
  color: #ff6b6b;
  cursor: pointer;
  font-size: 0.88rem;
  font-weight: 700;
  padding: 8px 20px;
}

.settings-delete-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.settings-error {
  color: #ff6b6b;
  font-size: 0.82rem;
  text-align: center;
}

.settings-success {
  color: var(--gold);
  font-size: 0.82rem;
  text-align: center;
}

.settings-input {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  box-sizing: border-box;
  color: #fff;
  font-size: 0.9rem;
  padding: 10px 12px;
  width: 100%;
}

.settings-input:focus {
  border-color: var(--gold);
  outline: none;
}

.settings-textarea {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  box-sizing: border-box;
  color: #fff;
  font-family: inherit;
  font-size: 0.9rem;
  padding: 10px 12px;
  resize: vertical;
  width: 100%;
}

.settings-textarea:focus {
  border-color: var(--gold);
  outline: none;
}

.settings-char-count {
  color: rgba(255, 255, 255, 0.4);
  font-size: 0.75rem;
  text-align: right;
}

/* プロフィール編集ページ */
.top-title--sm {
  font-size: 1.4rem;
  margin-bottom: 6px;
}

.settings-page-header {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-bottom: 8px;
}

.settings-back-btn {
  align-items: center;
  align-self: flex-start;
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.55);
  cursor: pointer;
  display: flex;
  font-size: 0.8rem;
  gap: 5px;
  padding: 0;
}

.settings-back-btn:hover {
  color: rgba(255, 255, 255, 0.9);
}

.settings-file-input {
  display: none;
}

.profile-edit-image-area {
  display: flex;
  justify-content: center;
  padding: 8px 0 4px;
}

.profile-edit-image-actions {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 4px;
}

