/* LAYR / EuphoSip Coffee shop -------------------------------------------- */

/* hidden属性で消した部品は、display指定を持つ部品(.cartのgrid等)より必ず優先して消す。
   これが無いと「カートを空にしたのに、カートの枠が描画され続ける」type のバグになる */
[hidden] {
  display: none !important;
}

:root {
  --bg: #ffffff;
  --bg-raised: #faf9f7;
  --bg-raised-2: #f1efec;
  --line: #e6e3de;
  --line-strong: #cdc8c1;
  --text: #1a1a1c;
  --text-dim: #56534f;
  --text-faint: #76726d;
  --accent: #b35300;       /* 文字に使うオレンジ(白地で読める濃さ) */
  --accent-bright: #ff8e00; /* 塗りに使うブランドオレンジ */
  --accent-dim: #b35f00;
  --accent-soft: rgba(255, 142, 0, 0.10);
  --radius: 10px;
  --radius-sm: 6px;
  --wrap: 1120px;
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, 'Hiragino Kaku Gothic ProN', 'Noto Sans JP',
    'Yu Gothic UI', Meiryo, sans-serif;
  font-size: 15px;
  line-height: 1.75;
  letter-spacing: 0.01em;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

.wrap {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 20px;
}

/* ヘッダー --------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 1px 0 rgba(20, 18, 15, 0.04);
}

.coming-soon-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 16px;
  background: var(--accent-bright);
  color: #17120a;
  font-size: 13.5px;
  font-weight: bold;
  letter-spacing: .02em;
  text-align: center;
}

.coming-soon-bar .icon {
  stroke: #17120a;
}

@media (max-width: 480px) {
  .coming-soon-bar {
    padding: 8px 12px;
    font-size: 12.5px;
  }
}

/* お知らせバー(ヘッダーの下に1行。中身は notice.js が入れる) */
.notice-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px 16px;
  border-top: 1px solid rgba(179, 83, 0, .18);
  background: var(--accent-soft);
  color: #6b3200;
  font-size: 13.5px;
  font-weight: bold;
  letter-spacing: .02em;
  text-align: center;
}

.notice-bar .icon {
  flex: 0 0 auto;
  width: 17px;
  height: 17px;
  fill: none;
  stroke: #b35300;
  stroke-width: 2;
  stroke-linecap: round;
}

.notice-bar a {
  color: inherit;
  text-decoration: underline;
}

@media (max-width: 480px) {
  .notice-bar {
    padding: 7px 12px;
    font-size: 12.5px;
  }
}

.site-header__inner {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: baseline;
  gap: 10px;
  min-width: 0;
}

.brand__main {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.16em;
}

.brand__sub {
  font-size: 11px;
  color: var(--text-faint);
  letter-spacing: 0.12em;
  white-space: nowrap;
}

.header-spacer {
  flex: 1;
}

.cart-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font-size: 13px;
  transition: border-color 0.15s, color 0.15s;
}

.cart-link:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.cart-link__count {
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--accent-bright);
  color: #17120a;
  font-size: 12px;
  font-weight: 700;
  line-height: 20px;
  text-align: center;
}

.cart-link__count[hidden] {
  display: none;
}

.cart-link__count.is-bump {
  animation: cartCountBump .45s ease-out;
}

@keyframes cartCountBump {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.35); }
}

.icon {
  width: 17px;
  height: 17px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}

/* 見出し ---------------------------------------------------------------- */

.page-head {
  padding: 44px 0 26px;
}

.page-head__title {
  margin: 0;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.page-head__lead {
  margin: 10px 0 0;
  color: var(--text-dim);
  font-size: 14px;
  max-width: 42em;
}

/* カテゴリ絞り込み ------------------------------------------------------- */

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-bottom: 28px;
}

.filter-chip {
  padding: 7px 15px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: transparent;
  color: var(--text-dim);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.15s;
}

.filter-chip:hover {
  border-color: var(--accent-dim);
  color: var(--text);
}

.filter-chip[aria-pressed='true'] {
  border-color: var(--accent-bright);
  background: var(--accent-soft);
  color: var(--accent);
}

/* 商品一覧 -------------------------------------------------------------- */

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(232px, 1fr));
  gap: 22px;
  padding-bottom: 64px;
}

.card {
  display: flex;
  flex-direction: column;
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color 0.18s, transform 0.18s;
  box-shadow: 0 1px 2px rgba(20, 18, 15, 0.04);
}

.card:hover {
  border-color: var(--line-strong);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(20, 18, 15, 0.10);
}

.card__thumb {
  position: relative;
  aspect-ratio: 1 / 1;
  background: var(--bg-raised-2);
  overflow: hidden;
}

.card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card__thumb--empty {
  display: grid;
  place-items: center;
  color: var(--text-faint);
  font-size: 12px;
}

.card__body {
  padding: 14px 15px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.card__cat {
  font-size: 11px;
  color: var(--text-faint);
  letter-spacing: 0.08em;
}

.card__name {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.55;
  flex: 1;
}

.card__price {
  font-size: 15px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.02em;
}

.card__price small {
  font-size: 11px;
  font-weight: 400;
  color: var(--text-faint);
  margin-left: 4px;
}

/* 状態バッジ ------------------------------------------------------------ */

.badge {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 11px;
  letter-spacing: 0.04em;
  border: 1px solid transparent;
}

.badge--soldout {
  background: rgba(0, 0, 0, 0.045);
  color: var(--text-dim);
  border-color: var(--line-strong);
}

.badge--order {
  background: var(--accent-soft);
  color: var(--accent);
  border-color: rgba(255, 142, 0, 0.35);
}

.card__thumb .badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(4px);
}

/* 商品ページ ------------------------------------------------------------ */

.detail {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 44px;
  padding: 24px 0 44px;
}

@media (max-width: 860px) {
  .detail {
    grid-template-columns: 1fr;
    gap: 20px;
    padding-top: 14px;
  }
}

.gallery__main {
  aspect-ratio: 1 / 1;
  background: var(--bg-raised-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.gallery__main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery__thumbs {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  flex-wrap: wrap;
}

.gallery__thumb {
  width: 62px;
  height: 62px;
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--bg-raised-2);
  overflow: hidden;
  cursor: pointer;
}

.gallery__thumb[aria-pressed='true'] {
  border-color: var(--accent);
}

.gallery__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail__cat {
  font-size: 11px;
  color: var(--text-faint);
  letter-spacing: 0.1em;
}

.detail__name {
  margin: 8px 0 14px;
  font-size: 22px;
  font-weight: 700;
  line-height: 1.5;
}

.detail__price {
  font-size: 28px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.01em;
}

.detail__price small {
  font-size: 12px;
  font-weight: 400;
  color: var(--text-faint);
  margin-left: 6px;
}

.detail__price-note {
  margin: 4px 0 0;
  font-size: 12px;
  color: var(--text-faint);
}

/* 選択肢 ---------------------------------------------------------------- */

.field {
  padding: 20px 0;
  border-top: 1px solid var(--line);
}

.field__label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  margin-bottom: 10px;
}

.field__label span {
  font-weight: 400;
  color: var(--text-faint);
  margin-left: 6px;
  font-size: 12px;
}

/* 受注生産の聞き取り項目 */
.field__required {
  margin-left: 6px;
  color: var(--accent);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.custom-other {
  margin-top: 8px;
}

.notice--custom {
  margin: 4px 0 16px;
}

/* 選び忘れたときの案内 */
.custom-error {
  margin: 0 0 8px;
  padding: 8px 10px;
  border: 1px solid rgba(196, 40, 30, 0.35);
  border-radius: var(--radius-sm);
  background: #fff5f4;
  color: #a3241c;
  font-size: 13px;
  font-weight: 600;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  min-width: 62px;
  padding: 9px 16px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--bg-raised);
  color: var(--text);
  font: inherit;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.15s;
}

.chip:hover:not(:disabled) {
  border-color: var(--accent-dim);
}

.chip[aria-pressed='true'] {
  border: 2px solid #b35300;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 600;
}

.chip:disabled {
  color: var(--text-faint);
  border-color: var(--line);
  background: transparent;
  cursor: not-allowed;
  text-decoration: line-through;
  text-decoration-color: var(--text-faint);
}

select.input,
input.input {
  width: 100%;
  max-width: 320px;
  padding: 10px 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: #ffffff;
  color: var(--text);
  font: inherit;
  font-size: 14px;
}

select.input:focus,
input.input:focus {
  outline: none;
  border-color: var(--accent);
}

.option-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 9px 0;
}

.option-row input[type='checkbox'] {
  width: 17px;
  height: 17px;
  margin: 4px 0 0;
  accent-color: var(--accent);
  flex: none;
}

.option-row label {
  cursor: pointer;
  font-size: 14px;
}

.option-row__price {
  color: var(--accent);
  font-weight: 600;
  margin-left: 6px;
}

.option-row__note {
  display: block;
  color: var(--text-dim);
  font-size: 12px;
  line-height: 1.65;
  margin-top: 2px;
}

/* 数量とボタン ---------------------------------------------------------- */

.buy {
  padding-top: 14px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.qty {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.qty button {
  width: 40px;
  height: 46px;
  border: 0;
  background: var(--bg-raised);
  color: var(--text);
  font: inherit;
  font-size: 18px;
  cursor: pointer;
}

.qty button:hover {
  color: var(--accent);
}

.qty input {
  width: 52px;
  height: 46px;
  border: 0;
  border-left: 1px solid var(--line);
  border-right: 1px solid var(--line);
  background: #ffffff;
  color: var(--text);
  font: inherit;
  font-size: 15px;
  text-align: center;
  -moz-appearance: textfield;
}

.qty input::-webkit-outer-spin-button,
.qty input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 46px;
  padding: 0 26px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font: inherit;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: filter 0.15s, border-color 0.15s, color 0.15s;
}

.btn--primary {
  position: relative;
  overflow: hidden;
  flex: 1;
  flex-basis: 200px;
  min-width: 200px;
  background: #d24800;
  color: #fff;
}

.btn--primary:hover:not(:disabled) {
  filter: brightness(1.05);
}

.btn--primary:active:not(:disabled) {
  transform: scale(.97);
}

.btn--primary.is-added {
  background: #1f7a44;
  color: #fff;
}

.btn--primary::after {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 42%;
  content: '';
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .55), transparent);
  opacity: 0;
  pointer-events: none;
  transform: translateX(-160%) skewX(-18deg);
}

.btn--primary.is-added::after {
  animation: addedButtonShine .6s ease-out;
}

@keyframes addedButtonShine {
  0% {
    opacity: 0;
    transform: translateX(-160%) skewX(-18deg);
  }
  20% { opacity: 1; }
  100% {
    opacity: 0;
    transform: translateX(350%) skewX(-18deg);
  }
}

@media (prefers-reduced-motion: reduce) {
  .btn--primary:active:not(:disabled) {
    transform: none;
  }

  .btn--primary.is-added::after,
  .cart-link__count.is-bump {
    animation: none;
  }
}

.btn--ghost {
  background: transparent;
  border-color: var(--line-strong);
  color: var(--text);
}

.btn--ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn:disabled {
  background: var(--bg-raised-2);
  color: var(--text-faint);
  cursor: not-allowed;
  border-color: var(--line);
}

/* 説明文 ---------------------------------------------------------------- */

.description {
  padding: 26px 0 0;
  border-top: 1px solid var(--line);
  margin-top: 20px;
  color: var(--text-dim);
  font-size: 14px;
}

.description :is(h1, h2, h3, h4) {
  color: var(--text);
  font-size: 15px;
  margin: 1.2em 0 .45em;
}

.description :first-child {
  margin-top: 0;
}

.description a {
  color: var(--accent);
  text-decoration: underline;
}

.description img {
  border-radius: var(--radius-sm);
  margin: 1em 0;
}

/* カート -------------------------------------------------------------- */

.cart {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 32px;
  align-items: start;
  padding-bottom: 44px;
}

/* 左列(商品明細+削除した商品)。右の会計欄の高さと無関係に上から積む */
.cart__main {
  min-width: 0;
}

@media (max-width: 860px) {
  .cart {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

.line {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr) auto;
  gap: 16px;
  padding: 13px 0;
  border-top: 1px solid var(--line);
}

.line:last-child {
  border-bottom: 1px solid var(--line);
}

.line__thumb {
  width: 88px;
  height: 88px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--bg-raised-2);
  border: 1px solid var(--line);
}

.line__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.line__body {
  min-width: 0;
}

.line__name {
  display: block;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.55;
}

.line__name:hover {
  color: var(--accent);
}

.line__sel {
  margin-top: 4px;
  font-size: 12px;
  color: var(--text-dim);
  line-height: 1.7;
}

.line__unit {
  margin-top: 4px;
  font-size: 12px;
  color: var(--text-faint);
}

.line__right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

.qty--sm button {
  width: 32px;
  height: 36px;
  font-size: 15px;
}

.qty--sm input {
  width: 44px;
  height: 36px;
  font-size: 14px;
}

.line__price {
  font-size: 15px;
  font-weight: 700;
  color: var(--accent);
}

.line__remove {
  border: 0;
  background: none;
  color: var(--text-faint);
  font: inherit;
  font-size: 12px;
  padding: 0;
  cursor: pointer;
  text-decoration: underline;
}

.line__remove:hover {
  color: #c0392b;
}

.cart__summary {
  position: sticky;
  top: 84px;
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: 0 2px 10px rgba(20, 18, 15, 0.05);
}

.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
}

/* display:flex は hidden属性より強いので、消すときはこちらで明示する */
.summary-row[hidden] {
  display: none;
  padding: 7px 0;
  font-size: 14px;
  color: var(--text-dim);
}

.summary-row--total {
  margin-top: 8px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  color: var(--text);
  font-size: 15px;
  font-weight: 600;
}

.summary-row--total span:last-child {
  font-size: 22px;
  font-weight: 700;
  color: var(--accent);
}

.summary-note {
  margin: 12px 0 0;
  font-size: 11.5px;
  line-height: 1.75;
  color: var(--text-faint);
}

.summary-note--merchant {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 4px;
  background: var(--bg-raised);
}

.summary-note--merchant strong {
  font-weight: 700;
}

/* 注意書き・お知らせ ---------------------------------------------------- */

.notice {
  display: flex;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 142, 0, 0.3);
  background: var(--accent-soft);
  border-radius: var(--radius-sm);
  color: #8a4b00;
  font-size: 13px;
  line-height: 1.7;
  margin: 12px 0 0;
}

.notice .icon {
  stroke: var(--accent);
  margin-top: 3px;
}

.state {
  padding: 70px 20px;
  text-align: center;
  color: var(--text-dim);
  font-size: 14px;
}

.state--error {
  color: #c0392b;
}

/* 読み込み中の仮のカード ------------------------------------------------ */

.card--skeleton {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  pointer-events: none;
}

.card--skeleton .card__body {
  padding: 14px 14px 18px;
}

.card--skeleton .card__body span {
  display: block;
  height: 11px;
  margin-bottom: 9px;
  border-radius: 3px;
}

.card--skeleton .card__body span:last-child {
  width: 55%;
  margin-bottom: 0;
}

.card--skeleton .card__thumb,
.card--skeleton .card__body span {
  background: linear-gradient(
    100deg,
    var(--bg-raised-2) 30%,
    var(--bg-raised) 50%,
    var(--bg-raised-2) 70%
  );
  background-size: 300% 100%;
  animation: skeletonSweep 1.3s ease-in-out infinite;
}

@keyframes skeletonSweep {
  from { background-position: 130% 0; }
  to { background-position: -30% 0; }
}

@media (prefers-reduced-motion: reduce) {
  .card--skeleton .card__thumb,
  .card--skeleton .card__body span {
    animation: none;
  }
}

.breadcrumb {
  padding: 12px 0 0;
  font-size: 12px;
  color: var(--text-faint);
}

.breadcrumb a:hover {
  color: var(--accent);
}

/* フッター -------------------------------------------------------------- */

.site-footer {
  border-top: 1px solid var(--line);
  margin-top: 40px;
  padding: 30px 0 50px;
  color: var(--text-faint);
  font-size: 12px;
}

.site-footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-bottom: 14px;
}

.site-footer__links a:hover {
  color: var(--accent);
}

/* 読み込み中のちらつき防止 */
[data-loading] {
  opacity: 0;
}

/* 商品詳細ページ: 合意済みデザイン -------------------------------------- */

:root {
  --price: #d24800;
  --ease-print: cubic-bezier(.2, .7, .2, 1);
}

.product-page {
  min-width: 0;
  overflow-x: clip;
}

.product-page--coffee {
  --price: #b4451a;
  --accent: #8a4423;
  --accent-bright: #c06a35;
  --accent-soft: rgba(192, 106, 53, .1);
  background:
    repeating-linear-gradient(
      to bottom,
      transparent 0 3px,
      rgba(91, 57, 34, .028) 3px 4px
    ),
    linear-gradient(to bottom, #fff 0, #fbf7f2 100%);
}

.product-page .brand__main,
.product-page .detail__name {
  font-family: 'Archivo', system-ui, sans-serif;
}

.product-main {
  max-width: 1180px;
}

.product-page .breadcrumb {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 10px;
  letter-spacing: .12em;
}

.product-page .detail {
  grid-template-columns: minmax(0, 1.08fr) minmax(360px, .92fr);
  align-items: start;
  gap: clamp(38px, 6vw, 76px);
  padding: 30px 0 88px;
}

.product-page .detail__info {
  position: sticky;
  top: 96px;
  min-width: 0;
}

.product-page .gallery {
  min-width: 0;
}

.product-page .gallery__main {
  position: relative;
  display: grid;
  aspect-ratio: 1;
  place-items: center;
  border-color: var(--line-strong);
  border-radius: 4px;
  background:
    repeating-linear-gradient(
      to bottom,
      transparent 0 3px,
      rgba(26, 26, 28, .045) 3px 4px
    ),
    var(--bg-raised-2);
}

.product-page .gallery__main img {
  width: 100%;
  height: 100%;
  padding: clamp(5px, 1vw, 12px);
  object-fit: contain;
}

.product-page .gallery__thumbs {
  display: flex;
  flex-wrap: nowrap;
  gap: 9px;
  margin-top: 12px;
  padding: 1px 1px 9px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scrollbar-color: var(--line-strong) transparent;
  scrollbar-width: thin;
}

.product-page .gallery__thumbs:empty {
  display: none;
}

.product-page .gallery__thumbs::-webkit-scrollbar {
  height: 5px;
}

.product-page .gallery__thumbs::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: var(--line-strong);
}

.product-page .gallery__thumb {
  position: relative;
  width: 70px;
  min-width: 70px;
  height: 70px;
  border-radius: 3px;
}

.product-page .gallery__thumb::after {
  position: absolute;
  right: 8px;
  bottom: 5px;
  left: 8px;
  height: 2px;
  content: '';
  background: var(--accent-bright);
  opacity: 0;
  transform: scaleX(0);
  transition: opacity .18s ease, transform .18s ease;
}

.product-page .gallery__thumb[aria-pressed='true'] {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent);
}

.product-page .gallery__thumb[aria-pressed='true']::after {
  opacity: 1;
  transform: scaleX(1);
}

.product-page .gallery__thumb img {
  object-fit: contain;
}

/* 前後へ移動する矢印。写真が2枚以上あるときだけ出る */
.product-page .gallery__arrow {
  position: absolute;
  top: 50%;
  z-index: 2;
  display: grid;
  width: 40px;
  height: 40px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: rgba(255, 255, 255, .82);
  color: var(--text);
  font-size: 22px;
  line-height: 1;
  place-items: center;
  transform: translateY(-50%);
  cursor: pointer;
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}
.product-page .gallery__arrow--prev { left: 8px; }
.product-page .gallery__arrow--next { right: 8px; }
.product-page .gallery__arrow:hover { background: #fff; }
.product-page .gallery__arrow:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* 動画は縦横比を保ったまま、写真の枠の中に収める */
.product-page .gallery__main .video-embed--stage {
  position: absolute;
  inset: 0;
  display: grid;
  margin: 0;
  place-items: center;
  border-radius: 0;
  background: #000;
}
.product-page .gallery__main .video-embed--stage iframe {
  position: static;
  width: 100%;
  height: auto;
  max-height: 100%;
  aspect-ratio: 16 / 9;
  border: 0;
}

/* 動画のサムネイル。写真と同じ大きさに切りそろえ、再生の印を重ねる */
.product-page .gallery__thumb--video { position: relative; }
.product-page .gallery__thumb--video img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.product-page .gallery__play {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, .25);
}
.product-page .gallery__play svg {
  width: 22px;
  height: 22px;
  fill: #fff;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, .6));
}

.product-page .gallery__thumb--model {
  display: grid;
  width: 82px;
  min-width: 82px;
  height: 70px;
  padding: 7px 5px 6px;
  place-items: center;
  background: var(--bg-raised);
  color: var(--text-dim);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 9px;
  letter-spacing: .08em;
  line-height: 1.2;
}

.product-page .gallery__thumb--model .icon {
  width: 23px;
  height: 23px;
}

.product-page .model-stage {
  position: relative;
  display: grid;
  place-items: center;
  background:
    repeating-linear-gradient(
      to bottom,
      transparent 0 3px,
      rgba(26, 26, 28, .045) 3px 4px
    ),
    var(--bg-raised-2);
}

.product-page .gallery__main .model-stage {
  position: absolute;
  inset: 0;
}

.product-page .model-stage model-viewer {
  width: 100%;
  height: 100%;
  touch-action: pan-y;
  --poster-color: transparent;
}

.product-page .model-stage__loading {
  position: absolute;
  z-index: 1;
  margin: 0;
  padding: 6px 9px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .9);
  color: var(--text-faint);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 10px;
  letter-spacing: .1em;
}

.product-page .model-stage.is-ready .model-stage__loading {
  display: none;
}

.product-page .gallery__color-model-note {
  margin: 3px 1px 0;
  color: var(--text-faint);
  font-size: 11px;
  line-height: 1.5;
}

.product-page .color-stage {
  height: 220px;
  margin-bottom: 12px;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 4px;
}

.product-page .color-stage__toggle {
  position: absolute;
  right: 8px;
  bottom: 8px;
  z-index: 2;
  min-height: 44px;
  padding: 8px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 3px;
  background: rgba(255, 255, 255, .9);
  color: var(--text-dim);
  font: inherit;
  font-size: 11px;
  cursor: pointer;
}

.product-page .color-stage__toggle:hover,
.product-page .color-stage__toggle:focus-visible {
  border-color: var(--accent);
  color: var(--accent);
  outline: none;
}

.product-intro {
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line-strong);
}

.product-page .detail__status {
  min-height: 25px;
  margin-bottom: 8px;
}

.product-page .detail__status:empty {
  display: none;
}

.product-page .detail__name {
  margin: 0;
  font-size: clamp(20px, 2.1vw, 29px);
  font-weight: 800;
  letter-spacing: -.02em;
  line-height: 1.32;
}

.product-page .detail__cat {
  margin-top: 11px;
  color: var(--text-faint);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 10px;
  letter-spacing: .18em;
  text-transform: uppercase;
}

.product-page .price-stack {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 12px;
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.product-page .detail__price,
.product-page .buy__price {
  color: var(--price);
  font-variant-numeric: tabular-nums;
}

.product-page .detail__price {
  min-width: 0;
  font-family: 'Archivo', system-ui, sans-serif;
  font-size: clamp(26px, 3.1vw, 36px);
  font-weight: 800;
  letter-spacing: -.02em;
  line-height: 1.12;
}

.product-page .detail__price small,
.product-page .buy__price small {
  color: var(--text-faint);
  font-family: system-ui, sans-serif;
  font-size: 11px;
  font-weight: 400;
}

.product-page .detail__price.is-changing,
.product-page .buy__price.is-changing {
  animation: priceChange .2s ease both;
}

@keyframes priceChange {
  from { opacity: .35; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

.product-page .detail__price-note {
  min-height: 0;
  margin-top: 0;
}

.product-page .field {
  padding: 14px 0;
  border-top-color: var(--line);
}

.product-page .product-fields .field:first-child {
  border-top: 0;
}

.product-page .field__label,
.product-page .section-label,
.product-page .badge {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 11px;
  letter-spacing: .18em;
  line-height: 1.5;
  text-transform: uppercase;
}

.product-page .field__label {
  margin-bottom: 8px;
}

.product-page .field__label span {
  display: inline-block;
  font-family: inherit;
  font-size: 9px;
  letter-spacing: .08em;
  text-transform: none;
}

.product-page .chips {
  gap: 9px;
}

.product-page .chip {
  min-width: 44px;
  min-height: 44px;
  max-width: 100%;
  padding: 9px 14px;
  border-radius: 3px;
  background: var(--bg);
  overflow-wrap: anywhere;
}

.product-page .chip:hover:not(:disabled),
.product-page .chip:focus-visible:not(:disabled) {
  border-color: var(--accent);
  outline: none;
}

.product-page .chip[aria-pressed='true'] {
  border-color: var(--accent);
  background: var(--accent-soft);
  box-shadow: inset 0 -2px 0 var(--accent);
  color: var(--accent);
}

.product-page .chip:disabled {
  background:
    repeating-linear-gradient(
      135deg,
      transparent 0 5px,
      rgba(26, 26, 28, .08) 5px 7px
    ),
    var(--bg-raised);
  color: #9a9690;
  opacity: .68;
  text-decoration: line-through;
}

.product-page .swatches {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(44px, 1fr));
  gap: 6px;
  padding-inline: 6px;
}

.product-page .swatches .chip.swatch {
  position: relative;
  width: 100%;
  min-width: 44px;
  min-height: 44px;
  aspect-ratio: 1;
  padding: 0;
  border: 1px solid rgba(26, 26, 28, .18);
  border-radius: 50%;
  background: var(--swatch);
  box-shadow: inset 0 0 0 4px rgba(255, 255, 255, .5);
  color: var(--text);
  cursor: pointer;
  overflow-wrap: normal;
  text-decoration: none;
  transform: scale(1);
  transition: transform .18s ease, box-shadow .18s ease;
}

.product-page .swatches .chip.swatch:hover:not(:disabled),
.product-page .swatches .chip.swatch:focus-visible:not(:disabled),
.product-page .swatches .chip.swatch[aria-pressed='true'] {
  z-index: 3;
  border-color: rgba(26, 26, 28, .18);
  outline: none;
  background: var(--swatch);
  box-shadow:
    inset 0 0 0 4px rgba(255, 255, 255, .58),
    0 8px 22px rgba(20, 18, 15, .16);
  color: var(--text);
  transform: scale(1.16);
}

.product-page .swatches .chip.swatch:disabled {
  border-color: rgba(26, 26, 28, .18);
  background: var(--swatch);
  color: var(--text);
  cursor: not-allowed;
  opacity: .72;
  text-decoration: none;
}

.product-page .swatch span {
  position: absolute;
  bottom: calc(100% + 7px);
  left: 50%;
  z-index: 4;
  width: max-content;
  max-width: calc(100vw - 48px);
  margin: 0;
  padding: 4px 7px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--text);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 9px;
  font-weight: 400;
  letter-spacing: .04em;
  line-height: 1.4;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 4px) translateX(var(--shift, 0px));
  transition: opacity .18s ease, transform .18s ease;
}

.product-page .swatch:hover span,
.product-page .swatch:focus-visible span,
.product-page .swatch[aria-pressed='true'] span {
  opacity: 1;
  transform: translate(-50%, 0) translateX(var(--shift, 0px));
}

.product-page .swatch--soldout::after {
  position: absolute;
  inset: 8%;
  border-radius: 50%;
  content: '';
  background: repeating-linear-gradient(
    135deg,
    transparent 0 5px,
    rgba(26, 26, 28, .55) 5px 7px
  );
}

@media (min-width: 560px) {
  .product-page .color-stage {
    height: 280px;
  }

  .product-page .swatches {
    grid-template-columns: repeat(auto-fill, minmax(44px, 1fr));
    gap: 6px;
  }
}

@media (min-width: 900px) {
  .product-page .color-stage {
    height: 320px;
  }

  .product-page .swatches {
    grid-template-columns: repeat(auto-fill, minmax(44px, 1fr));
  }
}

.product-page .color-stage.is-expanded {
  height: 62vh;
}

.product-page select.input {
  min-height: 44px;
  border-radius: 3px;
}

.product-page .option-row {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  align-items: start;
  gap: 10px;
  padding: 10px 0;
}

.product-page .option-row input[type='checkbox'] {
  width: 20px;
  height: 20px;
  margin-top: 2px;
}

.product-page .option-row label {
  min-width: 0;
}

.product-page .option-row__price {
  color: var(--price);
  font-variant-numeric: tabular-nums;
}

.product-page .option-row__note {
  max-width: 46em;
  margin-top: 4px;
}

.product-page .purchase-panel {
  padding-top: 22px;
  border-top: 1px solid var(--line-strong);
}

.product-page .buy {
  padding-top: 0;
  border-top: 0;
}

.product-page .buy__selection {
  flex-basis: 100%;
  margin: 0;
  overflow: hidden;
  color: var(--text-dim);
  font-size: 12px;
  line-height: 1.5;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-page .buy__price {
  display: none;
}

.product-page .shipping-note {
  margin: 11px 0 0;
  color: var(--text-faint);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 10px;
  letter-spacing: .08em;
}

.product-page .notice {
  border-radius: 3px;
}

.product-page .description-section {
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px solid var(--line-strong);
}

.product-page .section-label {
  margin: 0 0 10px;
  color: var(--accent);
}

.product-page .description {
  margin: 0;
  padding: 0;
  border: 0;
  color: var(--text-dim);
  font-size: 14px;
}

.product-page .description :is(h2, h3) {
  margin: 1.4em 0 .5em;
  color: var(--text);
  font-family: 'Archivo', system-ui, sans-serif;
  font-weight: 600;
  letter-spacing: -.01em;
  line-height: 1.4;
}

.product-page .description h2 {
  font-size: 20px;
}

.product-page .description h3 {
  font-size: 17px;
}

.product-page .description :is(p, ul, ol) {
  margin: 0 0 1.15em;
}

.product-page .description :is(ul, ol) {
  padding-left: 1.5em;
}

.product-page .description li + li {
  margin-top: .38em;
}

.product-page .description strong {
  color: var(--text);
}

.product-page .description a {
  text-underline-offset: .2em;
}

.product-page .description img {
  width: auto;
  max-width: 100%;
  height: auto;
  border-radius: 3px;
}

.product-page .description table {
  display: block;
  width: max-content;
  max-width: 100%;
  margin: 1.4em 0;
  border-collapse: collapse;
  overflow-x: auto;
  white-space: nowrap;
}

.product-page .description :is(th, td) {
  padding: 9px 12px;
  border: 1px solid var(--line);
  text-align: left;
}

.product-page .description th {
  background: var(--bg-raised);
  color: var(--text);
}

/* JavaScriptが止まっても、1.2秒後には本体と装飾線を同時に出し切る。 */
.product-page .reveal {
  position: relative;
}

.product-page .reveal::after {
  position: absolute;
  inset: 0;
  z-index: 5;
  border-top: 2px solid var(--accent-bright);
  content: '';
  opacity: 0;
  pointer-events: none;
  transform: translateY(100%);
}

.js .product-page .reveal {
  clip-path: inset(100% 0 0 0);
  opacity: 0;
  transform: translateY(22px);
  animation: productRevealBody .62s var(--ease-print) 1.2s both;
}

.js .product-page .reveal::after {
  animation: productRevealHead .62s linear 1.2s both;
}

.js .product-page .reveal.is-in {
  animation: productRevealBody .62s var(--ease-print) var(--delay, 0ms) both;
}

.js .product-page .reveal.is-in::after {
  animation: productRevealHead .62s linear var(--delay, 0ms) both;
}

@keyframes productRevealBody {
  from { clip-path: inset(100% 0 0 0); opacity: 0; transform: translateY(22px); }
  to { clip-path: inset(0 0 0 0); opacity: 1; transform: translateY(0); }
}

@keyframes productRevealHead {
  0% { opacity: 0; transform: translateY(100%); }
  10%, 82% { opacity: 1; }
  100% { opacity: 0; transform: translateY(0); }
}

@media (max-width: 899px) {
  .product-page .detail {
    grid-template-columns: minmax(0, 1fr);
    gap: 28px;
    padding-top: 22px;
  }

  .product-page .detail__info {
    position: static;
  }

  .product-page .detail__name {
    font-size: clamp(20px, 5.4vw, 26px);
  }

  .product-page .purchase-panel {
    display: contents;
  }

  .product-page .buy {
    position: sticky;
    bottom: 0;
    z-index: 18;
    display: grid;
    grid-template-columns: auto auto minmax(120px, 1fr);
    flex-wrap: nowrap;
    gap: 8px;
    margin: 0 -20px;
    padding: 10px max(20px, env(safe-area-inset-left))
      calc(10px + env(safe-area-inset-bottom))
      max(20px, env(safe-area-inset-right));
    border-top: 1px solid var(--line-strong);
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 -8px 28px rgba(20, 18, 15, .08);
    backdrop-filter: blur(12px);
  }

  .product-page .buy__price {
    display: flex;
    align-items: center;
    min-width: 64px;
    font-family: 'Archivo', system-ui, sans-serif;
    font-size: 16px;
    font-weight: 800;
    white-space: nowrap;
  }

  .product-page .buy__selection {
    grid-column: 1 / -1;
  }

  .product-page .buy__price small {
    display: none;
  }

  .product-page .buy .qty button {
    width: 34px;
    height: 44px;
  }

  .product-page .buy .qty input {
    width: 40px;
    height: 44px;
  }

  .product-page .buy .btn {
    min-width: 0;
    height: 44px;
    padding-inline: 12px;
    font-size: 15px;
    white-space: nowrap;
  }

  .product-page .shipping-note {
    margin-top: 14px;
  }

  .product-page .description-section {
    margin-top: 20px;
  }

  .product-page .site-footer {
    margin-top: 0;
  }
}

@media (max-width: 420px) {
  .product-page .buy {
    grid-template-columns: auto 106px minmax(104px, 1fr);
    padding-right: max(12px, env(safe-area-inset-right));
    padding-left: max(12px, env(safe-area-inset-left));
  }

  .product-page .buy .qty button {
    width: 32px;
  }

  .product-page .buy .qty input {
    width: 40px;
  }

  .product-page .buy .btn {
    font-size: 14px;
    letter-spacing: .02em;
  }
}

@media (prefers-reduced-motion: reduce) {
  .product-page *,
  .product-page *::before,
  .product-page *::after {
    animation: none !important;
    scroll-behavior: auto !important;
    transition: none !important;
  }

  .js .product-page .reveal {
    clip-path: inset(0 0 0 0) !important;
    opacity: 1 !important;
    transform: none !important;
  }

  .product-page .reveal::after {
    display: none;
  }
}

/* 商品説明の文字色 ------------------------------------------------------ */
/* 管理画面の「文字色」で付けた色を、お店のページでも同じように出す。
   管理画面側(admin.css)と必ず同じ色にすること。★片方だけ変えない */

.description .tc-red    { color: #c0392b; }
.description .tc-orange { color: #b35300; }
.description .tc-green  { color: #2e7d4f; }
.description .tc-gray   { color: #6b6660; }

/* 商品説明に貼った YouTube を、画面幅に合わせて表示する */
.description .video-embed {
  position: relative;
  margin: 1.2em 0;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 10px;
  background: var(--bg-raised-2);
}

.description .video-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* トップページ: 合意済みデザイン ---------------------------------------- */

html.home {
  scroll-behavior: smooth;
  scroll-padding-top: 112px;
  overflow-x: clip;
}

.home-page {
  --paper: #ffffff;
  --paper-2: #faf9f7;
  --paper-3: #f1efec;
  --ink: #1a1a1c;
  --ink-dim: #56534f;
  --ink-faint: #76726d;
  --price: #d24800;
  --wrap: 1180px;
  --header-height: 76px;
  --header-shrink: 18px;
  --ease-print: cubic-bezier(.2, .7, .2, 1);
  min-width: 0;
  overflow-x: clip;
  background: var(--paper);
  color: var(--ink);
}

.home-page .latin,
.home-page .brand__main,
.home-page .marquee__track {
  font-family: 'Archivo', system-ui, sans-serif;
}

.home-page .eyebrow,
.home-page .card__cat {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-variant-numeric: tabular-nums;
}

.home-page .wrap,
.home-page .site-header__inner,
.home-page .hero__inner {
  width: min(100% - 40px, var(--wrap));
  max-width: none;
  margin-inline: auto;
  padding-inline: 0;
}

.home-page .layer-lines {
  background-image: repeating-linear-gradient(
    to bottom,
    transparent 0 3px,
    rgba(26, 26, 28, .045) 3px 4px
  );
}

/* 背景3D */
.home-page .background-model {
  position: fixed;
  top: 84px;
  right: max(8px, .5vw);
  z-index: 0;
  width: min(50vw, 560px);
  height: min(50vw, 560px);
  opacity: .92;
  pointer-events: none;
  transition: opacity .5s ease;
}

.home-page .background-model.is-hidden {
  opacity: 0;
}

.home-page .background-model model-viewer {
  width: 100%;
  height: 100%;
  pointer-events: none;
  --poster-color: transparent;
}

/* ヘッダーは既存構造のまま、デザイン案の表現を適用 */
.home-page .site-header {
  top: 0;
  z-index: 30;
  border-bottom: 0;
  background: rgba(255, 255, 255, .94);
  box-shadow: none;
  backdrop-filter: blur(12px);
  clip-path: inset(0 0 0 0);
  transition: clip-path .25s ease, box-shadow .25s ease;
}

.home-page .site-header::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 4px;
  content: '';
  background-image: repeating-linear-gradient(
    to bottom,
    transparent 0 1px,
    rgba(26, 26, 28, .12) 1px 2px
  );
  opacity: 0;
  transform: translateY(0) scaleY(.35);
  transform-origin: bottom;
  transition: opacity .25s ease, transform .25s ease;
}

.home-page .site-header.is-scrolled {
  clip-path: inset(0 0 var(--header-shrink) 0);
  box-shadow: 0 4px 18px rgba(20, 18, 15, .05);
}

/* お知らせバーが出ているときは、縮める演出をやめる(バーの文字が切れるため) */
.home-page .site-header.has-notice.is-scrolled {
  clip-path: inset(0 0 0 0);
}

/* 同じ理由で、下端の飾り線も出さない(バーの下で二重線に見えるため) */
.home-page .site-header.has-notice::after {
  display: none;
}

.home-page .site-header.has-notice.is-scrolled .site-header__inner {
  transform: none;
}

.home-page .site-header.is-scrolled::after {
  opacity: 1;
  transform: translateY(calc(-1 * var(--header-shrink))) scaleY(1);
}

.home-page .site-header__inner {
  height: var(--header-height);
  padding-block: 0;
  gap: 24px;
  transition: transform .25s ease;
}

/* clip-pathで下端を削るぶん、中身を半分だけ上げて縁との余白を保つ */
.home-page .site-header.is-scrolled .site-header__inner {
  transform: translateY(calc(-.5 * var(--header-shrink)));
}

.home-page .brand__main {
  font-size: 21px;
  font-weight: 800;
}

.home-page .brand__sub {
  color: var(--ink-faint);
  letter-spacing: .1em;
}

/* ヒーロー */
.home-page .hero {
  position: relative;
  z-index: 1;
  height: auto;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(
    100deg,
    rgba(250, 249, 247, .97) 0%,
    rgba(250, 249, 247, .95) 34%,
    rgba(250, 249, 247, .55) 56%,
    rgba(250, 249, 247, 0) 76%
  );
  overflow: hidden;
}

.home-page .hero__inner {
  display: flex;
  align-items: center;
  padding-top: clamp(38px, 5vw, 64px);
  padding-bottom: clamp(46px, 6vw, 78px);
}

.home-page .hero__copy {
  position: relative;
  z-index: 1;
  width: min(100%, 940px);
  min-width: 0;
}

.home-page .eyebrow {
  margin: 0 0 18px;
  color: var(--accent);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.5;
  letter-spacing: .18em;
}

.home-page .hero__title {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  margin: 0;
  color: var(--ink);
  font-size: clamp(58px, 9vw, 112px);
  font-weight: 800;
  letter-spacing: -.03em;
  line-height: .94;
  gap: 0 .16em;
}

.home-page .hero__title::after {
  position: absolute;
  inset: 0;
  border-top: 2px solid var(--accent-bright);
  content: '';
  filter: drop-shadow(0 0 5px rgba(255, 142, 0, .55));
  opacity: 0;
  pointer-events: none;
  transform: translateY(100%);
}

.js .home-page .hero__title {
  clip-path: inset(100% 0 0 0);
  animation: homeHeroPrint .9s var(--ease-print) 1.4s both;
}

.js .home-page .hero__title::after {
  animation: homeHeroHead .9s var(--ease-print) 1.4s both;
}

.home-page.is-ready .hero__title {
  animation: homeHeroPrint .9s var(--ease-print) .12s both;
}

.home-page.is-ready .hero__title::after {
  animation: homeHeroHead .9s var(--ease-print) .12s both;
}

.home-page .hero__cross {
  font-size: .42em;
  font-weight: 500;
}

.home-page .hero__partner {
  font-size: clamp(24px, 4.3vw, 52px);
  letter-spacing: -.035em;
}

@keyframes homeHeroPrint {
  from { clip-path: inset(100% 0 0 0); }
  to { clip-path: inset(0 0 0 0); }
}

@keyframes homeHeroHead {
  0% { opacity: 0; transform: translateY(100%); }
  8%, 84% { opacity: 1; }
  100% { opacity: 0; transform: translateY(0); }
}

/* 共通見出しとプリント出現 */
.home-page .section-head {
  max-width: 760px;
  margin-bottom: clamp(24px, 4vw, 42px);
}

.home-page .section-head h2 {
  margin: 0;
  font-size: clamp(30px, 4.8vw, 58px);
  font-weight: 700;
  letter-spacing: -.035em;
  line-height: 1.12;
}

.home-page .print-reveal {
  position: relative;
}

.home-page .print-reveal::after {
  position: absolute;
  inset: 0;
  z-index: 5;
  border-top: 3px solid var(--accent-bright);
  content: '';
  filter: drop-shadow(0 0 10px color-mix(in srgb, var(--accent-bright) 85%, transparent));
  opacity: 0;
  pointer-events: none;
  transform: translateY(100%);
}

/* JSが途中で止まっても、挿入から1.4秒後には必ず表示する。 */
.js .home-page .print-reveal {
  clip-path: inset(100% 0 0 0);
  opacity: 0;
  transform: translateY(26px);
  animation: homeRevealBody .62s var(--ease-print) 1.4s both;
}

.js .home-page .print-reveal::after {
  animation: homeRevealHead .62s linear 1.4s both;
}

.js .home-page .print-reveal.is-in {
  animation: homeRevealBody .62s var(--ease-print) var(--delay, 0ms) both;
}

.js .home-page .print-reveal.is-in::after {
  animation: homeRevealHead .62s linear var(--delay, 0ms) both;
}

@keyframes homeRevealBody {
  from { clip-path: inset(100% 0 0 0); opacity: 0; transform: translateY(26px); }
  to { clip-path: inset(0 0 0 0); opacity: 1; transform: none; }
}

@keyframes homeRevealHead {
  0% { opacity: 0; transform: translateY(100%); }
  10%, 82% { opacity: 1; }
  100% { opacity: 0; transform: translateY(0); }
}

/* 商品一覧 */
.home-page .home-state {
  position: relative;
  z-index: 2;
  background: var(--paper);
}

.home-page .catalog {
  position: relative;
  z-index: 1;
  padding: clamp(56px, 8vw, 110px) 0;
  background: rgba(255, 255, 255, .55);
}

.home-page .catalog[hidden] {
  display: none;
}

.home-page .product-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(10px, 2.2vw, 28px);
  padding-bottom: 0;
}

.home-page .card {
  position: relative;
  display: flex;
  min-width: 0;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 0;
  background: var(--paper-2);
  box-shadow: none;
  overflow: visible;
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

.home-page .card:hover,
.home-page .card:focus-visible {
  border-color: var(--line-strong);
  box-shadow: 0 14px 34px rgba(20, 18, 15, .08);
  transform: translateY(-3px);
}

.home-page .card:active {
  transform: scale(.985);
}

.home-page .card__thumb {
  position: relative;
  aspect-ratio: 1;
  background: var(--paper-3);
  overflow: hidden;
}

.home-page .card__thumb::after {
  position: absolute;
  inset: 0;
  content: '';
  background-image: repeating-linear-gradient(
    to bottom,
    transparent 0 3px,
    rgba(26, 26, 28, .055) 3px 4px
  );
  opacity: 0;
  pointer-events: none;
  transform: translateY(-100%);
}

.home-page .card:hover .card__thumb::after,
.home-page .card:focus-visible .card__thumb::after,
.home-page .card:active .card__thumb::after {
  animation: homeCardScan .75s var(--ease-print) once;
}

.home-page .card__thumb img {
  width: 100%;
  height: 100%;
  padding: clamp(4px, .8vw, 10px);
  object-fit: contain;
  transition: transform .6s var(--ease-print);
}

.home-page .card:hover .card__thumb img,
.home-page .card:focus-visible .card__thumb img,
.home-page .card:active .card__thumb img {
  transform: scale(1.035);
}

.home-page .card__thumb--empty {
  height: 100%;
}

.home-page .card__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 0;
  padding: 0;
}

.home-page .card__name {
  display: -webkit-box;
  min-height: 2.9em;
  margin: clamp(12px, 2vw, 24px) clamp(10px, 1.7vw, 18px) clamp(5px, .8vw, 8px);
  overflow: hidden;
  font-size: clamp(12px, 1.6vw, 18px);
  font-weight: 600;
  line-height: 1.45;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.home-page .card__cat {
  margin: 0 clamp(10px, 1.7vw, 18px) clamp(12px, 1.8vw, 20px);
  color: var(--ink-faint);
  font-size: clamp(8px, 1vw, 11px);
  letter-spacing: .18em;
}

.home-page .card__price {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 10px;
  margin-top: auto;
  padding: clamp(9px, 1.4vw, 14px) clamp(10px, 1.7vw, 18px);
  border-top: 1px solid var(--line);
  color: var(--price);
  font-size: clamp(15px, 1.9vw, 19px);
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  letter-spacing: .01em;
}

.home-page .card__price small {
  margin-left: 0;
  color: var(--ink-faint);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: clamp(7px, .8vw, 9px);
  font-weight: 400;
  line-height: 1.4;
  text-align: right;
}

.home-page .card__thumb .badge {
  z-index: 2;
}

.home-page .card--skeleton {
  overflow: hidden;
}

.home-page .card--skeleton:hover {
  border-color: var(--line);
  box-shadow: none;
  transform: none;
}

.home-page .card--skeleton .card__body {
  padding: 14px 14px 18px;
}

@keyframes homeCardScan {
  0% { opacity: 0; transform: translateY(-100%); }
  18%, 72% { opacity: 1; }
  100% { opacity: 0; transform: translateY(100%); }
}

/* コーヒー */
.home-page .tone-coffee {
  --paper-2: #f8f4ef;
  --paper-3: #f0e8df;
  --line: #e5dbd0;
  --accent: #8a4423;
  --accent-bright: #c06a35;
  --price: #b4451a;
  padding-top: clamp(72px, 9vw, 120px);
  padding-bottom: clamp(72px, 9vw, 120px);
  border-top: 0;
  background:
    repeating-linear-gradient(
      to bottom,
      transparent 0 3px,
      rgba(91, 57, 34, .04) 3px 4px
    ),
    linear-gradient(
      to bottom,
      #fff 0,
      #e7d8c5 100px,
      #e7d8c5 calc(100% - 100px),
      #fff 100%
    );
  overflow: hidden;
}

.home-page .tone-coffee .wrap {
  position: relative;
  z-index: 1;
}

.home-page .tone-coffee .card {
  border-radius: 14px;
  background: #fffdfa;
  overflow: hidden;
}

.home-page .steam {
  position: absolute;
  top: 12%;
  right: 8%;
  width: 220px;
  height: 420px;
  border: 18px solid var(--accent);
  border-top-color: transparent;
  border-bottom-color: transparent;
  border-radius: 50%;
  filter: blur(26px);
  opacity: .035;
  animation: homeSteamDrift 7s ease-in-out infinite alternate;
}

.home-page .steam::before,
.home-page .steam::after {
  position: absolute;
  width: 110px;
  height: 260px;
  border: 14px solid var(--accent);
  border-top-color: transparent;
  border-bottom-color: transparent;
  border-radius: 50%;
  content: '';
}

.home-page .steam::before {
  right: 110px;
  bottom: -90px;
}

.home-page .steam::after {
  top: -90px;
  left: 110px;
}

@keyframes homeSteamDrift {
  from { transform: translateY(22px) rotate(-4deg); }
  to { transform: translateY(-28px) rotate(5deg); }
}

/* フッターとマーキー */
.home-page .site-footer {
  position: relative;
  z-index: 1;
  margin-top: 0;
  padding: 0;
  border-top: 0;
  background: var(--paper);
}

.home-page .marquee {
  overflow: hidden;
  border-block: 1px solid var(--line-strong);
  background: var(--accent-bright);
  color: #17120a;
}

.home-page .marquee__track {
  display: flex;
  width: max-content;
  font-size: clamp(24px, 4vw, 48px);
  font-weight: 800;
  letter-spacing: -.02em;
  line-height: 1;
  animation: homeMarquee 22s linear infinite;
}

.home-page .marquee__track span {
  padding: 18px 0;
  white-space: nowrap;
}

.home-page .site-footer__bottom {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding-top: 34px;
  padding-bottom: 48px;
  color: var(--ink-faint);
  font-size: 11px;
}

.home-page .site-footer__links {
  margin-bottom: 0;
}

@keyframes homeMarquee {
  to { transform: translateX(-50%); }
}

@media (min-width: 560px) {
  .home-page .product-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 900px) {
  .home-page .product-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .home-page {
    --header-height: 62px;
    --header-shrink: 6px; /* ボタンが縦に大きいので、削りすぎると縁に触れる */
  }

  .home-page .wrap,
  .home-page .site-header__inner,
  .home-page .hero__inner {
    width: min(100% - 32px, var(--wrap));
  }

  .home-page .background-model {
    top: 132px;
    right: 4px;
    width: min(76vw, 380px);
    height: min(76vw, 380px);
    opacity: .9;
  }

  .home-page .brand {
    gap: 6px;
  }

  .home-page .brand__main {
    font-size: 17px;
  }

  .home-page .brand__sub {
    max-width: 130px;
    overflow: hidden;
    font-size: 9px;
    text-overflow: ellipsis;
  }

  .home-page .cart-link {
    padding: 7px 11px;
  }

  .home-page .hero {
    padding-bottom: clamp(96px, 30vw, 150px);
    background: linear-gradient(
      168deg,
      rgba(250, 249, 247, .97) 0%,
      rgba(250, 249, 247, .95) 46%,
      rgba(250, 249, 247, .5) 68%,
      rgba(250, 249, 247, 0) 88%
    );
  }

  .home-page .hero__inner {
    align-items: flex-start;
    padding-block: 34px;
  }

  .home-page .hero__title {
    font-size: clamp(52px, 16vw, 68px);
  }

  .home-page .hero__partner {
    font-size: clamp(23px, 7.2vw, 31px);
  }

  .home-page #parts {
    padding-top: 36px;
  }

  .home-page #parts .eyebrow {
    margin-bottom: 8px;
  }

  .home-page #parts .section-head {
    margin-bottom: 18px;
  }

  .home-page .product-grid--coffee {
    gap: 12px;
  }

  .home-page .site-footer__bottom {
    flex-direction: column;
    gap: 12px;
  }
}

@media (max-width: 390px) {
  .home-page .card__price {
    align-items: flex-start;
    flex-direction: column;
  }

  .home-page .card__price small {
    text-align: left;
  }
}

@media (prefers-reduced-motion: reduce) {
  html.home {
    scroll-behavior: auto;
  }

  .home-page *,
  .home-page *::before,
  .home-page *::after {
    animation: none !important;
    scroll-behavior: auto !important;
    transition: none !important;
  }

  .home-page .hero__title,
  .home-page .print-reveal {
    clip-path: inset(0 0 0 0) !important;
    opacity: 1 !important;
    transform: none !important;
  }

  .home-page .hero__title::after,
  .home-page .print-reveal::after {
    display: none;
  }

  .home-page .marquee__track {
    transform: none;
  }
}

/* マイページ・会員 ------------------------------------------------------ */

.account {
  max-width: 440px;
  margin: 0 auto;
}

.account--wide {
  max-width: 720px;
}

.account-form {
  display: grid;
  gap: 16px;
}

.account-form .btn {
  width: 100%;
}

.account-note {
  margin: 0 0 18px;
  font-size: 13.5px;
  line-height: 1.9;
  color: var(--text-dim);
}

.account-check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  color: var(--text-dim);
  cursor: pointer;
}

.account-check input {
  width: 16px;
  height: 16px;
  accent-color: var(--accent-bright);
}

.account-check--sub {
  margin-top: 8px;
}

.account-links {
  display: grid;
  gap: 10px;
  margin-top: 22px;
  font-size: 13.5px;
}

.account-links a {
  color: var(--accent);
  text-decoration: none;
}

.account-links a:hover {
  text-decoration: underline;
}

.form-msg {
  margin: 0;
  font-size: 13.5px;
  color: #c0392b;
}

.form-msg[role='status'] {
  color: var(--text-dim);
}

.form-msg.form-msg--ok {
  color: #2e7d32;
}

.form-msg:empty {
  display: none;
}

.member-card {
  display: grid;
  gap: 10px;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-raised);
}

.member-card__row {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 14px;
  font-size: 14px;
}

.member-card__label {
  min-width: 8em;
  color: var(--text-dim);
}

.member-card__actions {
  margin-top: 6px;
}

.account-heading {
  margin: 34px 0 12px;
  font-size: 16px;
}

.order-history {
  display: grid;
  gap: 14px;
}

.order-card {
  display: grid;
  gap: 8px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.order-card__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 14px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}

.order-card__number {
  font-size: 14px;
  font-weight: 700;
}

.order-card__date {
  font-size: 13px;
  color: var(--text-dim);
}

.order-chip {
  margin-left: auto;
  padding: 3px 10px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font-size: 12px;
  color: var(--text-dim);
  white-space: nowrap;
}

.order-chip--paid {
  border-color: var(--accent-dim);
  background: var(--accent-soft);
  color: var(--accent);
}

.order-chip--done {
  border-color: #2e7d32;
  background: rgba(46, 125, 50, 0.08);
  color: #2e7d32;
}

.order-card__item {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 14px;
}

.order-card__item-amount {
  white-space: nowrap;
}

.order-card__variation {
  margin-top: -4px;
  font-size: 12.5px;
  color: var(--text-dim);
}

.order-card__total {
  display: flex;
  justify-content: space-between;
  padding-top: 8px;
  border-top: 1px solid var(--line);
  font-size: 14px;
  font-weight: 700;
}

/* 狭い画面のヘッダー: 枠を外して、アイコンの下に小さく文字を添える(アプリ風)。
   マイページが増えて、枠つきの横並びでは収まらないため */
@media (max-width: 480px) {
  .site-header__inner {
    gap: 6px;
    padding: 10px 14px;
  }

  .cart-link {
    position: relative;
    flex-direction: column;
    gap: 4px;
    padding: 5px 9px;
    border: 0;
    font-size: 10px;
    letter-spacing: 0.06em;
    line-height: 1;
  }

  .cart-link .icon {
    width: 21px;
    height: 21px;
  }

  /* カートの数はアイコンの右肩に小さく重ねる */
  .cart-link__count {
    position: absolute;
    top: -2px;
    right: -2px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    font-size: 10.5px;
    line-height: 16px;
  }
}

/* 登録済みメールアドレスで登録しようとしたときの案内 */
.account-registered {
  margin-top: 16px;
  padding: 16px 18px;
  border: 1px solid var(--accent-dim);
  border-radius: var(--radius);
  background: var(--accent-soft);
  font-size: 13.5px;
  line-height: 1.8;
}

.account-registered p {
  margin: 0 0 8px;
}

.account-registered__actions {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

/* ポイント(カートの利用欄・マイページの履歴) ------------------------ */

.summary-row--points span:last-child {
  color: var(--accent);
  font-weight: 600;
}

.cart-points {
  margin-top: 14px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--bg-raised);
}

.cart-points__head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 13px;
  color: var(--text-dim);
}

.cart-points__head strong {
  font-size: 16px;
  color: var(--text);
}

.cart-points__controls {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
}

.cart-points__label {
  font-size: 13px;
  color: var(--text-dim);
  white-space: nowrap;
}

.cart-points__controls input {
  width: 90px;
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  font-size: 15px;
  text-align: right;
}

.cart-points__all {
  padding: 8px 12px;
  font-size: 13px;
  white-space: nowrap;
}

.cart-points__note {
  margin: 10px 0 0;
  font-size: 12px;
  line-height: 1.7;
  color: var(--text-faint);
}

.cart-points__login {
  margin: 12px 0 0;
  font-size: 12.5px;
  color: var(--text-dim);
}

/* マイページのポイント表示 */

.member-card__points-value {
  font-size: 17px;
  color: var(--accent);
}

/* 会員登録ボタンの下の同意文 */
.account-consent {
  margin: 10px 0 0;
  font-size: 12.5px;
  color: var(--text-faint);
}

.member-card__points-rate {
  display: block;
  margin-top: 4px;
  font-size: 12.5px;
  color: var(--text-dim);
}

/* 文章の中のリンク。押せることが分かるように、色を変えて下線を引く */
.text-link,
.cart-points__note a,
.member-card__points-rate a,
.account-consent a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.text-link:hover,
.cart-points__note a:hover,
.member-card__points-rate a:hover,
.account-consent a:hover {
  color: var(--accent-dim);
}

.member-card__points-note {
  display: block;
  margin-top: 2px;
  font-size: 12px;
  color: var(--text-faint);
}

.order-card__points {
  display: flex;
  justify-content: space-between;
  padding-top: 6px;
  font-size: 13px;
  color: var(--accent);
}

/* 小計・送料。値引きの行と同じ並びで、合計の内訳を示す */
.order-card__sum {
  display: flex;
  justify-content: space-between;
  padding-top: 6px;
  font-size: 13px;
  color: var(--text-dim);
}

.order-card__sum + .order-card__sum {
  padding-top: 2px;
}

.point-history {
  display: grid;
  gap: 0;
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}

.point-row {
  display: grid;
  grid-template-columns: 6em 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 10px 14px;
  background: var(--bg-raised);
  font-size: 13.5px;
}

.point-row + .point-row {
  border-top: 1px solid var(--line);
}

.point-row__date {
  color: var(--text-faint);
  font-size: 12.5px;
}

.point-row__note {
  display: block;
  font-size: 12px;
  color: var(--text-faint);
}

.point-row__delta {
  font-weight: 600;
  white-space: nowrap;
}

.point-row__delta--plus {
  color: var(--accent);
}

@media (max-width: 480px) {
  .point-row {
    grid-template-columns: 1fr auto;
  }
  .point-row__date {
    grid-column: 1 / -1;
  }
}

/* クーポン入力欄(カート) ------------------------------------ */

.cart-coupon__controls {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}

.cart-coupon__controls input {
  flex: 1;
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  font-size: 15px;
  text-transform: uppercase;
}

.cart-coupon__controls input::placeholder {
  text-transform: none;
  font-size: 13px;
  color: var(--text-faint);
}

.cart-coupon__msg {
  margin: 8px 0 0;
  font-size: 12.5px;
  color: #b02a20;
}

.cart-coupon__msg:empty {
  display: none;
}

.cart-coupon__msg--ok {
  color: var(--accent);
}

/* 削除した商品(カートに戻せる) ------------------------------------ */

.cart-trash {
  max-width: 720px;
  margin: 6px 0 44px;
  /* カート本体との見切り線(店主の要望) */
  padding-top: 18px;
  border-top: 1px solid var(--line-strong);
}

/* カートの左列では、商品明細のすぐ下に付ける */
.cart__main .cart-trash {
  margin: 26px 0 0;
}

.cart-trash__title {
  margin: 0 0 4px;
  font-size: 16px;
}

.cart-trash__note {
  margin: 0 0 12px;
  font-size: 12.5px;
  color: var(--text-faint);
}

.trash-line {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 1px dashed var(--line-strong);
  border-radius: 10px;
  background: var(--bg-raised);
}

.trash-line + .trash-line {
  margin-top: 8px;
}

.trash-line__body {
  min-width: 0;
}

.trash-line__name {
  display: block;
  font-size: 14px;
  color: var(--text-dim);
}

.trash-line__sel {
  display: block;
  font-size: 12px;
  color: var(--text-faint);
}

.trash-line__meta {
  display: block;
  margin-top: 2px;
  font-size: 12px;
  color: var(--text-faint);
}

.trash-line__actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
  flex-shrink: 0;
}

.trash-line__restore {
  padding: 7px 12px;
  font-size: 13px;
  white-space: nowrap;
}

.trash-line__discard {
  border: 0;
  background: none;
  padding: 2px;
  font-size: 11.5px;
  color: var(--text-faint);
  text-decoration: underline;
  cursor: pointer;
}
