:root {
  --bottom-panel-height: calc(110px + env(safe-area-inset-bottom, 0px));
}

body {
  margin: 0;
  font-family: sans-serif;
  background-color: #000;
  color: white;
  padding-bottom: 130px;
  text-align: center;
}

button,
a,
select,
input,
[role="button"] {
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

header {
  position: relative;
}

.main-header {
  position: relative;
}

.main-title {
  text-align: center;
  margin: 0;
  line-height: 60px;
}

.feedback-link {
  position: absolute;
  top: 16px;
  right: 24px;
}

.feedback-link img {
  width: 24px;
}

h1 {
  font-size: 24px;
  margin-top: 16px;
  margin-bottom: 8px;
  line-height: 1.2;
}

.top-container {
  position: sticky;
  top: 0;
  z-index: 90; /* 画面下部の設定エリア（z-index: 99）やフッターボタン（z-index: 100）の下 */
  background-color: #f8f8f8; /* タイマーと同色の不透明背景で裏側を隠す */
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); /* スクリール時に境界線として浮き上がらせる */
  border-bottom: 1px solid #e0e0e0;
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}

#timer-display {
  font-size: 62px;
  line-height: 1;
  margin: 0;
  padding: 0;
  font-weight: bold;
  font-variant-numeric: tabular-nums;
  color: #1a1a1a;
  background-color: transparent;
}

.control-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
}

.control-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0px;
  font-size: 24px;
}

.control-group button {
  width: 32px;
  height: 32px;
  font-size: 18px;
  background-color: #444;
  color: white;
  border: none;
  border-radius: 4px;
}

.recipe-section {
  margin-top: 4px;
  margin-bottom: 0;
}

.recipe-section__heading {
  margin-top: 8px;
  margin-bottom: 4px;
  font-size: 20px;
}

.recipe-container {
  max-width: 400px;
  margin: 0 auto;
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  gap: 4px;
  padding-bottom: calc(140px + var(--bottom-panel-height));
  padding-left: 12vw;
  padding-right: 12vw;
  box-sizing: border-box;
  transition: padding-bottom 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}

.recipe-card {
  width: 320px;
  min-width: 320px;
  max-width: 320px;
  box-sizing: border-box;
  flex: 0 0 auto;
  scroll-snap-align: center;
  background: #181818;
  border-radius: 12px;
  margin: 0 2px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  padding: 12px 14px;
}

@media (max-width: 340px) {
  .recipe-card {
    width: calc(100vw - 24px);
    min-width: calc(100vw - 24px);
    max-width: calc(100vw - 24px);
  }
}

.recipe-card h3 {
  margin-top: 0;
  margin-bottom: 6px;
  font-size: 18px;
  text-align: center;
  padding: 0 48px; /* 左右のアクションボタン（左：履歴、右：コピー）と重ならないように */
}

.recipe-card.custom-recipe h3 {
  padding: 0 48px; /* 左上（履歴1個）と右上（三点リーダー1個）と重ならないように */
}

.recipe-desc {
  color: #ffffff; /* 純白 */
  margin: 2px 0 4px;
  text-align: center;
}

/* 長いメモ・説明の折りたたみ */
.recipe-desc-collapsible {
  position: relative;
  max-height: 2.8em;
  overflow: hidden;
  transition: max-height 0.25s ease-out;
  cursor: pointer;
  padding: 0 4px;
}

.recipe-desc-collapsible.expanded {
  max-height: 800px;
  transition: max-height 0.35s ease-in;
}

.recipe-desc-collapsible:not(.expanded)::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1.4em;
  background: linear-gradient(to bottom, rgba(17, 17, 17, 0), rgba(17, 17, 17, 0.95));
  pointer-events: none;
}

.recipe-desc-toggle-btn {
  background: none;
  border: none;
  color: #c98a4b;
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
  padding: 2px 6px;
  margin-top: 1px;
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.recipe-desc-toggle-btn:hover {
  text-decoration: underline;
}

.recipe-link {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: fit-content;
  margin: 2px auto 4px;
  font-weight: 500;
  color: #ffffff; /* 純白 */
  text-decoration: underline;
  transition: opacity 0.2s ease;
}

.recipe-link:hover {
  color: #ffffff;
  opacity: 0.8;
  text-decoration: underline;
}

.recipe-card ul {
  padding-left: 0;
  list-style: none;
  font-size: 14px;
  line-height: 1.45;
  margin-top: 6px;
  margin-bottom: 4px;
  text-align: left;
}

.recipe-card li {
  margin-bottom: 5px;
  position: relative;
  padding-left: 12px; /* バーを表示するための余白 */
  max-width: 100%;
  white-space: normal;
  transition: all 0.2s ease;
}

.recipe-card li.active {
  font-weight: bold;
  color: #fff;
}

.recipe-card li.active::before,
.recipe-card li.blink::before {
  content: "";
  position: absolute;
  left: 0;
  top: 2px;
  bottom: 2px;
  width: 4px;
  background: #f59e0b; /* アクセントのオレンジ */
  border-radius: 2px;
}

.recipe-card li.blink::before {
  animation: blink-step 1s infinite;
}

@keyframes blink-step {
  0%, 49.9% { opacity: 1; }
  50%, 100% { opacity: 0; }
}

.recipe-card li strong {
  display: inline-block;
  min-width: 45px;
  margin-right: 8px; /* 時間と説明の間の余白 */
  color: #fff;
}

/* レシピ切り替えタブ */
.recipe-tabs {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 6px 0 6px;
  padding: 0 16px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.recipe-tabs::-webkit-scrollbar {
  display: none;
}

.recipe-tabs .ice-toggle-btn {
  margin-left: auto;
  flex-shrink: 0;
}

.tab-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 1.5px solid rgba(255, 255, 255, 0.32);
  color: #e5e7eb;
  padding: 7px 15px;
  border-radius: 20px; /* より丸みのあるデザイン */
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  white-space: nowrap;
  flex-shrink: 0;
}

.tab-btn:hover {
  border-color: rgba(255, 255, 255, 0.65);
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.tab-btn.active {
  background: rgba(245, 158, 11, 0.12);
  border: 2px solid #f59e0b; /* アクセントのオレンジ */
  color: #f59e0b;
  font-weight: 700;
}

/* フリータブと＋作成ボタンの幅を揃える */
.tab-btn[data-tab="free"],
.tab-btn--create {
  min-width: 68px;
}

/* ＋作成ボタン（アイコン化・通常時は白系点線、選択時はオレンジ） */
.tab-btn--create {
  border: 1.5px dashed rgba(255, 255, 255, 0.55);
  color: #ffffff;
  background: rgba(255, 255, 255, 0.02);
  padding: 7px 13px;
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}

.tab-btn--create:hover {
  border-color: rgba(255, 255, 255, 0.95);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.tab-btn--create.active {
  border: 2px solid #f59e0b;
  color: #f59e0b;
  background: rgba(245, 158, 11, 0.12);
}

/* フリー抽出カード（横スクロール不要のため左右余白を小さくして広く表示） */
body.free-tab-active .recipe-container {
  padding-left: 12px;
  padding-right: 12px;
  overflow-x: visible;
}

body.free-tab-active #recipe-group-free {
  width: 100%;
  min-width: 100%;
}

.free-brew-card {
  width: 100%;
  min-width: 0;
  max-width: 100%;
  margin: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  text-align: left;
  box-sizing: border-box;
}

.free-brew-card h3 {
  font-size: 20px;
  margin: 8px 0 8px 0;
  color: #fff;
}

.free-brew-tips {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 16px;
  margin-top: 10px;
}

.free-brew-tip-title {
  font-size: 16px;
  font-weight: 700;
  color: #f59e0b;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.free-brew-tips ul {
  list-style: disc;
  padding-left: 20px;
  margin: 0;
}

.free-brew-tips li {
  font-size: 15px;
  color: #e5e7eb;
  line-height: 1.65;
  margin-bottom: 10px;
  padding: 0 !important;
  border: none !important;
}

.free-brew-tips li:last-child {
  margin-bottom: 0;
}

/* レシピグループ（タブごとの表示制御） */
.recipe-group {
  display: none;
  min-width: 100%;
  width: max-content;
}

.recipe-group.active {
  display: flex;
  gap: 4px;
}

.recipe-card {
  position: relative;
}

/* アクションボタン（デフォルトは標準レシピ用の絶対配置） */
/* アクションボタン（左上：履歴ボタン用） */
.recipe-card__actions-left {
  position: absolute;
  top: 8px;
  left: 8px;
  display: flex;
  gap: 8px;
}

/* アクションボタン（右上：コピー・編集・削除用） */
.recipe-card__actions-right {
  position: absolute;
  top: 8px;
  right: 8px;
  display: flex;
  gap: 8px;
}

.recipe-card__btn {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 6px;
  color: #ddd;
  font-size: 16px;
  cursor: pointer;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.recipe-card__btn--history,
.recipe-card__btn--more {
  width: 38px;
  height: 38px;
}

.recipe-card__btn:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.25);
  border-color: rgba(255, 255, 255, 0.4);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

.recipe-card__btn:active {
  transform: translateY(0);
}

.recipe-card__btn--delete:hover {
  color: #fff;
  background: rgba(255, 82, 82, 0.8);
  border-color: #ff5252;
}

/* レシピカード 三点リーダー ドロップダウンメニュー */
.recipe-card__dropdown-menu {
  display: none;
  position: absolute;
  top: 42px;
  right: 0;
  background: #222222;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.65);
  z-index: 120;
  min-width: 170px;
  width: max-content;
  padding: 6px 0;
  overflow: hidden;
  white-space: nowrap;
}

.recipe-card__dropdown-menu .dropdown-item {
  padding: 12px 18px;
  cursor: pointer;
  display: flex !important;
  align-items: center !important;
  gap: 12px;
  font-size: 14px;
  color: #e0e0e0;
  text-decoration: none;
  width: 100% !important;
  height: auto !important;
  box-sizing: border-box !important;
  white-space: nowrap !important;
  transition: background 0.15s ease, color 0.15s ease;
}

.recipe-card__dropdown-menu .dropdown-item:hover,
.recipe-card__dropdown-menu .dropdown-item:active {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}

.recipe-card__dropdown-menu .dropdown-item svg {
  flex-shrink: 0;
}

/* カスタムレシピ モーダル内のステップ行 */
.custom-step-row {
  position: relative;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.1); 
  border-radius: 16px;
  padding: 36px 14px 16px;
  margin-bottom: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: background 0.2s;
  box-sizing: border-box;
}

.step-index {
  position: absolute;
  top: 10px;
  left: 16px;
  font-size: 11px;
  font-weight: 600;
  color: #888;
  letter-spacing: 0.5px;
}

.custom-step-row:hover {
  background: rgba(255, 255, 255, 0.05);
}

/* 削除ボタン：右上の赤い円形ボタン */
.custom-step-remove {
  position: absolute;
  top: 10px;
  right: 12px;
  width: 26px;
  height: 26px;
  background: #ff5252 !important;
  border: 1px solid #fff !important;
  color: #fff !important;
  border-radius: 50% !important;
  font-size: 16px !important;
  font-weight: bold !important;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 3px 8px rgba(0,0,0,0.5);
  z-index: 20;
  transition: transform 0.2s, background 0.2s;
  padding: 0;
  line-height: 1;
}

.custom-step-remove:hover {
  background: #ff1744 !important;
  transform: scale(1.1);
}

/* 合計表示の文字（大きくする） */
#custom-weight-sum {
  font-size: 14px !important;
  font-weight: 500;
  color: #fff;
}

/* ステップのコンテナ */
#custom-steps-container {
  padding: 8px 4px 16px;
  max-height: 400px;
  overflow-y: auto;
  box-sizing: border-box;
}

/* 時間と注入量の並び（グリッドで安定化） */
/* ヘッダー行 */
.custom-steps-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 10px;
  padding: 0 18px;
  margin-bottom: 4px;
}

.custom-steps-header span {
  font-size: 12px;
  color: #9ca3af;
  font-weight: 500;
  letter-spacing: 0.05em;
}

.input-group {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.input-group.full-width {
  width: 100%;
}

.custom-step-inputs {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 10px;
  width: 100%;
  margin-top: 4px;
}

.step-total-display {
  font-size: 11px;
  color: #888;
  margin-top: 4px;
  text-align: right;
  padding-right: 4px;
}

.time-adjust-placeholder {
  width: 32px;
  height: 42px;
  flex-shrink: 0;
}

/* 時間入力：[-] 0:00 [+] */
.time-input-container {
  display: flex;
  align-items: center;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid #374151;
  border-radius: 12px;
  overflow: hidden;
  height: 44px;
  margin-top: 4px;
  width: 100%;
  box-sizing: border-box;
}

.time-adjust {
  background: #222;
  border: none;
  color: #fff;
  width: 32px;
  height: 100%;
  cursor: pointer;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
  flex-shrink: 0;
  padding: 0;
}

.time-adjust:hover { background: #333; }

.input-time {
  flex: 1;
  min-width: 0;
  background: transparent;
  border: none;
  color: #fff;
  text-align: center;
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  font-variant-numeric: tabular-nums;
  width: 100%;
  padding: 0 2px;
  box-sizing: border-box;
}

.input-time:focus { outline: none; }

.input-g, .input-desc {
  background: rgba(0, 0, 0, 0.4); 
  border: 1px solid #374151;
  border-radius: 12px;
  color: #fff;
  padding: 12px;
  font-size: 15px;
  font-family: inherit;
  margin-top: 4px;
  box-sizing: border-box;
  width: 100%;
  transition: all 0.2s;
}

.input-g:focus, .input-desc-editable:focus {
  border-color: #f59e0b;
  background: rgba(0, 0, 0, 0.6);
  outline: none;
}

.input-desc-editable {
  min-height: 70px;
  background: rgba(0, 0, 0, 0.4); 
  border: 1px solid #374151;
  border-radius: 12px;
  color: #fff;
  padding: 12px;
  font-size: 15px;
  font-family: inherit;
  margin-top: 4px;
  box-sizing: border-box;
  width: 100%;
  transition: all 0.2s;
  line-height: 1.6;
  outline: none;
  word-break: break-all;
  white-space: pre-wrap;
}

.input-desc-editable:empty:before {
  content: attr(placeholder);
  color: #555;
  pointer-events: none;
}

.weight-chip {
  display: inline-flex;
  align-items: center;
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid #f59e0b;
  color: #f59e0b;
  padding: 0 6px;
  border-radius: 6px;
  font-weight: 600;
  margin: 0 2px;
  font-size: 0.9em;
  vertical-align: baseline;
  user-select: none;
}

.desc-helpers {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.helper-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid #374151;
  color: #9ca3af;
  font-size: 11px;
  padding: 6px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 2px;
}

.helper-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: #f59e0b;
  color: #fff;
}

.helper-btn .val {
  color: #f59e0b;
  font-weight: 600;
}

.percentage-badge {
  position: absolute;
  right: 8px;
  top: calc(50% + 2px);
  transform: translateY(-50%);
  font-size: 11px;
  color: #ff9800;
  pointer-events: none;
  background: rgba(0, 0, 0, 0.7);
  padding: 2px 4px;
  border-radius: 4px;
  line-height: 1;
}

.input-g {
  width: 100%;
  background: #000;
  border: 1px solid #374151;
  color: #fff;
  height: 44px;
  padding: 0 48px 0 12px; /* 右側にバッジ用の余白を確保 */
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  margin-top: 4px;
  box-sizing: border-box;
  -moz-appearance: textfield;
  appearance: textfield;
}

.input-g::-webkit-outer-spin-button,
.input-g::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}


/* Step details moved and consolidated at the top */

/* ===== 4:6メソッド セレクター ===== */
.recipe-46-selectors {
  margin: 12px 0 8px;
  padding: 10px 8px;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 8px;
}

.recipe-46-selectors .selector-group {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  margin-bottom: 8px;
}

.recipe-46-selectors .selector-group:last-child {
  margin-bottom: 0;
}

.recipe-46-selectors .selector-label {
  font-size: 11px;
  color: #888;
  letter-spacing: 0.5px;
  margin-left: 2px;
}

.recipe-46-selectors .selector-buttons {
  display: flex;
  gap: 4px;
  width: 100%;
}

.recipe-46-selectors .selector-btn {
  -webkit-appearance: none;
  appearance: none;
  flex: 1;
  padding: 8px 10px;
  font-size: 12px;
  border: 1px solid #374151;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.4);
  color: #9ca3af;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  white-space: nowrap;
  outline: none;
}

.recipe-46-selectors .selector-btn:hover {
  border-color: #f59e0b;
  color: #fff;
}

.recipe-46-selectors .selector-btn.active {
  background: rgba(245, 158, 11, 0.1);
  border-color: #f59e0b;
  color: #f59e0b;
  font-weight: 600;
}

.water-amount-section {
  position: fixed;
  bottom: var(--bottom-panel-height); /* スタートボタン (.bottom-buttons) と重ならないように底上げ */
  left: 0;
  right: 0;
  box-sizing: border-box;
  background: #0d0d0d; /* カード背景より暗いほぼ黒 */
  padding: 10px 0 6px;
  margin: 0;
  border-top: 1px solid #222;
  box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.6);
  z-index: 99; /* .bottom-buttons (z-index: 100) のすぐ下 */

  /* スライドイン・アウトのアニメーション用初期状態 */
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
  transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.3s ease;
  text-align: center;
}

.water-amount-section__heading {
  margin-top: 8px;
  margin-bottom: 0;
  font-size: 20px;
}

.water-amount-display {
  font-size: 20px;
  font-weight: bold;
  margin-bottom: 4px;
}

.water-amount-controls {
  display: flex;
  justify-content: center;
  gap: 24px;
}

.control-label {
  font-size: 1.2rem;
  margin-bottom: 4px;
}

.control-btn {
  background: #222;
  color: #fff;
  border: none;
  border-radius: 8px; /* Slightly larger radius for larger button */
  font-size: 1.8rem;
  width: 44px;
  height: 44px;
  margin: 0 4px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.control-value {
  font-size: 1.5rem;
  margin: 0 4px;
}

.control-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.bottom-buttons {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--bottom-panel-height);
  box-sizing: border-box;
  display: flex;
  justify-content: center;
  gap: 24px;
  padding-bottom: calc(12px + env(safe-area-inset-bottom, 0px)); /* 下部の余白を元の12pxに差し戻し */
  background: #0d0d0d; /* 設定セクションと同じ不透明なほぼ黒 */
  align-items: flex-end; /* ボタンを下寄せにし、設定パネルとの距離を元の間隔に戻す */
  pointer-events: none;
  z-index: 100;
}

.bottom-buttons button {
  pointer-events: auto;
  width: 72px;
  height: 72px;
  border: none;
  background: #222;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.bottom-buttons button.save-record-btn-corner {
  position: absolute;
  right: 14px;
  bottom: calc(16px + env(safe-area-inset-bottom, 0px)); /* 再生ボタン等の垂直中心（下から48px + env）に合わせる */
  width: 64px;
  height: 64px;
  background: #1f1f22;
  border: 2px solid #ffffff;
  border-radius: 18px;
  color: #ffffff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 0;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5), 0 0 10px rgba(255, 255, 255, 0.2);
  cursor: pointer;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
  overflow: visible !important;
}

/* 注目吹き出しバッジ（案2：待機中はオレンジのまま静かに文字上スライド切替、抽出完了時にトントン＋上スライド） */
.save-record-bubble {
  position: absolute;
  top: -22px;
  right: 0;
  left: auto;
  transform: none;
  background: #d97706;
  color: #ffffff;
  font-size: 13px;
  font-weight: 800;
  padding: 5px 12px;
  height: 26px;
  border-radius: 14px;
  border: none;
  white-space: nowrap;
  letter-spacing: 0.4px;
  line-height: 1;
  box-shadow: 0 2px 9px rgba(0, 0, 0, 0.65), 0 0 10px rgba(217, 119, 6, 0.5);
  pointer-events: none;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  transform-origin: bottom right;
  box-sizing: border-box;
}

.save-record-bubble::after {
  content: '';
  position: absolute;
  bottom: -5px;
  right: 26px;
  left: auto;
  transform: none;
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 5px solid #d97706;
}

.save-record-ticker-window {
  height: 16px;
  line-height: 16px;
  overflow: hidden;
  position: relative;
  text-align: center;
  min-width: 78px;
  display: block;
}

.save-record-ticker-track {
  display: flex;
  flex-direction: column;
  animation: saveRecordIdleTicker 9.0s infinite cubic-bezier(0.22, 1, 0.36, 1);
}

.save-record-ticker-item {
  height: 16px;
  line-height: 16px;
  font-size: 12.5px;
  font-weight: 800;
  display: block;
}

@keyframes saveRecordIdleTicker {
  0%, 42% { transform: translateY(0); }
  48%, 92% { transform: translateY(-16px); }
  98%, 100% { transform: translateY(-32px); }
}

/* 抽出完了（できあがり！）時：アンバー発光＋波紋＋トントン→上スライド切替 */
.bottom-buttons button.save-record-btn-corner.is-drip-completed {
  border-color: #fbbf24;
  background: linear-gradient(145deg, #312214, #1f1915);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.65), 0 0 20px rgba(245, 158, 11, 0.5);
}

.bottom-buttons button.save-record-btn-corner.is-drip-completed::before {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 20px;
  border: 2px solid rgba(251, 191, 36, 0.8);
  pointer-events: none;
  animation: saveRecordDoneRipple 3.6s infinite cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes saveRecordDoneRipple {
  0%, 24% { transform: scale(1); opacity: 0; }
  28% { transform: scale(1); opacity: 0.8; }
  62% { transform: scale(1.28); opacity: 0; }
  100% { transform: scale(1.28); opacity: 0; }
}

.bottom-buttons button.save-record-btn-corner.is-drip-completed .save-record-bubble {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.7), 0 0 16px rgba(245, 158, 11, 0.7);
  animation: saveRecordTontonKnock 3.6s infinite ease-in-out;
}

.bottom-buttons button.save-record-btn-corner.is-drip-completed .save-record-ticker-track {
  animation: saveRecordDoneTicker 7.2s infinite cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes saveRecordTontonKnock {
  0%, 22% { transform: translateY(0) scale(1); }
  28% { transform: translateY(-5px) scale(1.05); }
  34% { transform: translateY(0) scale(0.97); }
  40% { transform: translateY(-5px) scale(1.05); }
  47%, 100% { transform: translateY(0) scale(1); }
}

@keyframes saveRecordDoneTicker {
  0%, 23% { transform: translateY(0); }
  30%, 73% { transform: translateY(-16px); }
  80%, 100% { transform: translateY(-32px); }
}

/* 抽出完了後の記録誘導スライドインカード内のボタン */
.record-slide-banner-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 13px;
}

.record-slide-cta-btn {
  flex: 1;
  background: linear-gradient(135deg, #d97706, #b45309);
  color: #ffffff;
  border: none;
  border-radius: 10px;
  padding: 11px 14px;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 3px 10px rgba(217, 119, 6, 0.35);
  transition: transform 0.15s ease, filter 0.15s ease;
}

.record-slide-cta-btn:hover {
  filter: brightness(1.08);
}

.record-slide-cta-btn:active {
  transform: scale(0.97);
}

.record-slide-later-btn {
  padding: 11px 16px !important;
  font-size: 13.5px !important;
}

.record-slide-banner-footer {
  margin-top: 11px;
  padding-top: 9px;
}

.bottom-buttons button.save-record-btn-corner:hover {
  border-color: #ffffff;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.6), 0 0 16px rgba(255, 255, 255, 0.35);
  transform: translateY(-2px);
  animation: none;
}

.bottom-buttons button.save-record-btn-corner:active {
  transform: scale(0.94);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
  animation: none;
}

.bottom-buttons button.save-record-btn-corner svg {
  stroke: #ffffff;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.5));
}

.bottom-buttons button.save-record-btn-corner .save-record-btn-label {
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
  color: #ffffff;
  letter-spacing: 0.8px;
}

.bottom-buttons button img {
  width: 36px;
  height: 36px;
  filter: brightness(0) invert(1);
}



/* Records List */
.records-section { max-width: 600px; margin: 0 auto; }
.records-heading { display: flex; align-items: center; gap: 16px; margin-bottom: 24px; }
.records-header-back { text-decoration: none; font-size: 24px; color: #9cf; }
.records-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 16px; }
.record-item { background: #111; border: 1px solid #222; border-radius: 16px; overflow: hidden; display: flex; flex-direction: column; text-align: left; }
.record-item__top { padding: 12px 16px; background: #1a1a1a; display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid #222; }
.record-item__date { font-size: 12px; color: #888; }
.record-item__stars { font-size: 14px; color: #f5a623; }
.record-item__content { padding: 16px; }
.record-item__recipe { font-size: 17px; font-weight: 700; margin: 0 0 8px 0; }
.record-item__details { display: flex; gap: 16px; font-size: 13px; color: #aaa; margin-bottom: 12px; }
.record-item__memo { font-size: 14px; color: #ccc; background: #181818; padding: 10px; border-radius: 8px; margin: 8px 0 0 0; white-space: pre-wrap; }
.record-item__footer { padding: 8px 16px; background: #0d0d0d; display: flex; justify-content: flex-end; }
.record-item__actions { display: flex; gap: 16px; }
.record-item__actions button { 
  background: rgba(255, 255, 255, 0.08); 
  border: 1px solid rgba(255, 255, 255, 0.12); 
  border-radius: 8px;
  font-size: 16px; 
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer; 
  color: #aaa; 
  transition: all 0.2s ease; 
  box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}
.record-item__edit-btn:hover { 
  color: #fff; 
  background: rgba(255, 255, 255, 0.2); 
  border-color: rgba(255, 255, 255, 0.4);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}
.record-item__delete-btn:hover { 
  color: #fff; 
  background: rgba(255, 82, 82, 0.8); 
  border-color: #ff5252;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}
.record-item__actions button:active {
  transform: translateY(0);
}

/* Modal Styles */
.record-modal { 
  position: fixed; 
  inset: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4); /* より透過させる */
  backdrop-filter: blur(10px); /* 公開サイトのグラスモーフィズム */
  -webkit-backdrop-filter: blur(10px);
  display: flex; 
  align-items: center; 
  justify-content: center; 
  z-index: 1000; 
  padding: 24px 16px; 
  box-sizing: border-box;
  text-align: left; 
}

.record-modal__content { 
  background: rgba(26, 26, 26, 0.8) !important; /* 半透明 */
  border: 1px solid rgba(255, 255, 255, 0.1); /* 微細な境界線 */
  border-radius: 20px; 
  width: 100%; 
  max-width: 400px; 
  padding: 32px; 
  box-sizing: border-box; 
  max-height: min(86vh, 100%); 
  margin: auto;
  overflow-y: auto; 
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

@media (max-width: 768px) {
  .record-modal {
    padding: 20px 16px;
  }
  .record-modal__content {
    max-height: 100%;
  }
}

.record-modal__title { font-size: 20px; font-weight: bold; margin: 0 0 24px 0; color: #fff; text-align: center; }
.record-modal__field { margin-bottom: 20px; display: flex; flex-direction: column; gap: 6px; }
.record-modal__field label { font-size: 12px; color: #9ca3af; font-weight: 500; }
.record-modal__value { font-size: 16px; font-weight: bold; color: #fff; }
.record-modal__textarea { 
  width: 100%; 
  background: rgba(0, 0, 0, 0.2); 
  border: 1px solid #374151; 
  border-radius: 12px; 
  padding: 12px; 
  color: #fff; 
  font-family: inherit; 
  font-size: 14px; 
  box-sizing: border-box; 
  resize: vertical; 
  transition: border-color 0.2s;
}

.record-modal__textarea:focus { border-color: #f59e0b; outline: none; }

.record-modal__actions { display: flex; gap: 12px; margin-top: 32px; }
.record-modal__actions button { 
  padding: 14px 10px; 
  border: none; 
  border-radius: 12px; 
  font-size: 15px; 
  font-weight: 600; 
  cursor: pointer; 
  transition: transform 0.1s, filter 0.2s;
  white-space: nowrap;
}

.record-modal__actions button:active { transform: scale(0.98); }

.record-modal__cancel { flex: 0 0 35%; max-width: 120px; background: #374151; color: #fff; }
.record-modal__save { flex: 1; background: #f59e0b; color: #fff; }
.record-modal__status { margin-top: 16px; font-size: 13px; color: #9ca3af; text-align: center; }

.record-modal__add-photo-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px dashed #374151;
  border-radius: 12px;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
  box-sizing: border-box;
}

.record-modal__add-photo-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: #f59e0b;
}

.record-modal__add-photo-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  border-color: #374151;
  background: rgba(255, 255, 255, 0.02);
}

.modal-photo-preview-container {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.modal-photo-preview-item {
  position: relative;
  width: 80px;
  height: 80px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid #374151;
  flex-shrink: 0;
}

.modal-photo-preview-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.modal-photo-preview-item .remove-btn {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 18px;
  height: 18px;
  background: rgba(0, 0, 0, 0.6);
  border-radius: 50%;
  border: none;
  color: #fff;
  font-size: 10px;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}


.star-rating {
  font-size: 36px;
  color: #444;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
}
.star-rating .star {
  display: inline-block;
  padding: 4px;
}
.star-rating .star.active {
  color: #ffb400;
}


/* --- Recipe History Filter & Summary Cards --- */

.recipe-filter-container {
  position: relative;
  margin-bottom: 20px;
  width: 100%;
}

/* スクロールエリアのフェードグラデーション効果（右端をフェードアウト） */
.recipe-filter-container::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 40px;
  background: linear-gradient(to right, transparent, #0a0a0a);
  pointer-events: none;
  z-index: 2;
}

.recipe-filter-scroll {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 8px 40px 8px 0; /* 右側はフェードマスク用にパディングをあける */
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
}

/* スクロールバーの非表示（Firefox/Chrome用） */
.recipe-filter-scroll::-webkit-scrollbar {
  display: none;
}
.recipe-filter-scroll {
  -ms-overflow-style: none;  /* IE and Edge */
  scrollbar-width: none;  /* Firefox */
}

/* フィルターチップ */
.filter-chip {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #aaa;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
}

.filter-chip:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-1px);
}

.filter-chip:active {
  transform: translateY(0);
}

/* アクティブ状態のフィルターチップ */
.filter-chip.active {
  background: rgba(122, 92, 58, 0.35); /* シックなブロンズ */
  border-color: rgba(245, 158, 11, 0.5); /* ゴールド境界 */
  color: #fff;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.15);
}

.filter-chip .chip-count {
  display: inline-block;
  background: rgba(255, 255, 255, 0.08);
  padding: 2px 6px;
  border-radius: 10px;
  font-size: 10px;
  font-weight: bold;
  margin-left: 6px;
  color: #888;
  transition: all 0.2s ease;
}

.filter-chip:hover .chip-count {
  color: #ccc;
  background: rgba(255, 255, 255, 0.15);
}

.filter-chip.active .chip-count {
  background: rgba(245, 158, 11, 0.25);
  color: #f59e0b;
}

/* 統計サマリーカード */
.recipe-summary-card {
  background: linear-gradient(135deg, rgba(26, 26, 26, 0.6), rgba(13, 13, 13, 0.8));
  border: 1px solid rgba(245, 158, 11, 0.15);
  border-radius: 16px;
  padding: 16px 20px;
  margin-bottom: 24px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.35s ease, transform 0.35s ease;
}

/* フェードインアニメーション */
.recipe-summary-card.fade-in {
  opacity: 1;
  transform: translateY(0);
}

.recipe-summary-card__header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding-bottom: 10px;
}

.recipe-summary-card__icon {
  font-size: 18px;
  color: #f59e0b;
}

.recipe-summary-title {
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  margin: 0;
}

.recipe-summary-card__stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  text-align: center;
}

.recipe-summary-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: rgba(255, 255, 255, 0.02);
  padding: 8px 4px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.03);
}

.recipe-summary-stat__label {
  font-size: 10px;
  color: #777;
  font-weight: 500;
  text-transform: uppercase;
}

.recipe-summary-stat__value {
  font-size: 18px;
  font-weight: 800;
  color: #fff;
  margin-top: 4px;
}

#recipe-summary-rating {
  color: #f59e0b;
}

/* 全体リセットボタン */
.reset-all-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid #333;
  color: #aaa;
  cursor: pointer;
  transition: all 0.2s ease;
  width: 100%;
  padding: 12px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  display: block;
  text-align: center;
  box-sizing: border-box;
}

.reset-all-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border-color: #f59e0b; /* アクセントのオレンジ */
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.1);
}

.reset-all-btn:active {
  transform: scale(0.98);
}

/* 湯量とリセットボタンを含むヘッダーの横並び設定 */
.water-amount-header {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 0 16px;
  box-sizing: border-box;
}

.water-amount-header #reset-all-container {
  margin: 0;
  display: flex;
  align-items: center;
}

/* 枠で囲ったコンパクトなリセットボタン */
.reset-link-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid #333;
  color: #aaa;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  padding: 6px 12px;
  border-radius: 6px;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.reset-link-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border-color: #f59e0b; /* アクセントのオレンジ */
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.15);
}

.reset-link-btn:active {
  transform: scale(0.95);
}

/* 全幅のトグルボタン（詳細設定用） */
.fullwidth-toggle-btn {
  width: 100%;
  background: #181818;
  border: none;
  border-top: 1px solid #2a2a2a;
  border-bottom: 1px solid #2a2a2a;
  color: #888;
  padding: 14px;
  font-size: 17px;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  border-radius: 0;
  transition: all 0.2s ease;
}

.fullwidth-toggle-btn .toggle-icon {
  font-size: 0.85em;
  display: inline-block;
  line-height: 1;
}

.fullwidth-toggle-btn:hover {
  background: #222;
  color: #bbb;
}

.fullwidth-toggle-btn:active {
  background: #111;
}

/* 抽出開始（timer-active）されたら、設定セクションをスライドアウトして隠す */
body.timer-active .water-amount-section {
  transform: translateY(200px); /* 135px以上の高さを画面外に押し下げる */
  opacity: 0;
  pointer-events: none;
  /* 消えるときは、出現時(0.3s)よりちょっとゆっくりめの 0.4s に設定 */
  transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.4s ease;
}

/* 抽出中もレシピカードの余白を維持し、スクロール位置の巻き戻し（ヘッダー再出現）を防ぐ */
body.timer-active .recipe-container {
  padding-bottom: calc(140px + var(--bottom-panel-height));
  transition: padding-bottom 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

/* ドロップダウンメニューの項目用スタイル */
.recipe-card__dropdown-menu .dropdown-item {
  transition: background 0.15s, color 0.15s;
}
.recipe-card__dropdown-menu .dropdown-item:hover {
  background: rgba(255, 255, 255, 0.08) !important;
  color: #fff !important;
}
.recipe-card__dropdown-menu .dropdown-item:active {
  background: rgba(255, 255, 255, 0.15) !important;
}

/* --- Ice Brew Mode Styles --- */
.ice-toggle-btn {
  background: transparent;
  border: 2px solid #38bdf8; /* 非選択時でも目立つ水色の単色枠線 */
  color: #38bdf8; /* テキストも水色にして視認性アップ */
  padding: 6px 11px;
  border-radius: 8px; /* 標準タブとは異なる四角い形状 */
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1.2;
  box-shadow: 0 0 6px rgba(56, 189, 248, 0.3); /* うっすら光らせる */
}

.ice-toggle-btn:hover {
  background: rgba(56, 189, 248, 0.15);
  box-shadow: 0 0 10px rgba(56, 189, 248, 0.5);
}

.ice-toggle-btn.active {
  background: #38bdf8; /* 選択時は背景色あり（塗りつぶし） */
  border-color: #38bdf8;
  color: #fff; /* 背景が明るい水色なので文字は白（お試し） */
  box-shadow: 0 0 12px rgba(56, 189, 248, 0.6);
}

/* Ice Mode Active Color Overrides */
body.ice-brew-active .recipe-card li.active::before,
body.ice-brew-active .recipe-card li.blink::before {
  background: #38bdf8;
}

body.ice-brew-active .tab-btn.active {
  border-color: #38bdf8;
  color: #38bdf8;
}

body.ice-brew-active .top-container,
body.ice-brew-active #timer-display {
  background-color: #f0f9ff;
  color: #0284c7;
}

body.ice-brew-active .record-modal__save {
  background: #38bdf8;
}

body.ice-brew-active .record-modal__textarea:focus {
  border-color: #38bdf8;
}

body.ice-brew-active .recipe-46-selectors .selector-btn:hover {
  border-color: #38bdf8;
}

body.ice-brew-active .recipe-46-selectors .selector-btn.active {
  background: rgba(56, 189, 248, 0.1);
  border-color: #38bdf8;
  color: #38bdf8;
}

/* 氷割合コントローラーのレイアウト */
.ice-only-control {
  transition: opacity 0.2s ease;
}

/* 氷の割合ボタンの基本デザイン */
#ice-ratio-selector {
  display: flex;
  align-items: center;
}

#ice-ratio-selector .ratio-btn {
  -webkit-appearance: none;
  appearance: none;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid #374151;
  border-radius: 8px;
  color: #9ca3af;
  font-size: 15px;
  font-weight: 500;
  padding: 8px 16px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  outline: none;
}

#ice-ratio-selector .ratio-btn:hover {
  border-color: #38bdf8;
  color: #fff;
}

body.ice-brew-active #ice-ratio-selector .ratio-btn.active {
  background: rgba(56, 189, 248, 0.1);
  border-color: #38bdf8;
  color: #38bdf8;
  font-weight: 600;
  box-shadow: 0 0 6px rgba(56, 189, 248, 0.15);
}

/* --- Bean Spec & AI Photo Parse Styles --- */
.bean-info-section {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(245, 158, 11, 0.2);
  border-radius: 10px;
  padding: 12px;
  margin-bottom: 14px;
  position: relative;
  overflow: hidden;
  text-align: left;
}

.bean-info-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.bean-info-title {
  font-size: 13px;
  font-weight: 700;
  color: #f59e0b;
  display: flex;
  align-items: center;
  gap: 6px;
}

.ai-badge {
  font-size: 10px;
  padding: 2px 7px;
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.25), rgba(245, 158, 11, 0.25));
  border: 1px solid rgba(168, 85, 247, 0.4);
  color: #e9d5ff;
  border-radius: 12px;
  font-weight: 600;
  letter-spacing: 0.5px;
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.ai-parse-trigger-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  padding: 9px 14px;
  margin-bottom: 12px;
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.2), rgba(245, 158, 11, 0.2));
  border: 1px solid rgba(168, 85, 247, 0.4);
  color: #f3e8ff;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.ai-parse-trigger-btn:hover:not(:disabled) {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.35), rgba(245, 158, 11, 0.35));
  border-color: rgba(245, 158, 11, 0.6);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(168, 85, 247, 0.2);
}

.ai-parse-trigger-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.ai-loading-overlay {
  display: none;
  padding: 12px;
  background: rgba(15, 23, 42, 0.85);
  border: 1px dashed rgba(168, 85, 247, 0.5);
  border-radius: 8px;
  text-align: center;
  margin-bottom: 12px;
  animation: pulse-border 1.5s infinite;
}

@keyframes pulse-border {
  0%, 100% { border-color: rgba(168, 85, 247, 0.4); }
  50% { border-color: rgba(245, 158, 11, 0.8); }
}

.ai-loading-text {
  font-size: 12px;
  font-weight: 600;
  background: linear-gradient(90deg, #e9d5ff, #fcd34d, #e9d5ff);
  background-size: 200% auto;
  color: transparent;
  -webkit-background-clip: text;
  background-clip: text;
  animation: shine 2s linear infinite;
}

@keyframes shine {
  to { background-position: 200% center; }
}

.ai-highlight-glow {
  animation: field-glow 2s ease-out;
}

@keyframes field-glow {
  0% {
    background-color: rgba(245, 158, 11, 0.25);
    border-color: #f59e0b;
    box-shadow: 0 0 10px rgba(245, 158, 11, 0.5);
  }
  100% {
    box-shadow: 0 0 0 rgba(245, 158, 11, 0);
  }
}

/* ==========================================================================
   AI Recipe Generator & Create Card (Issue #129)
   ========================================================================== */

/* ＋（レシピ作成）タブ選択時はタイマー・湯量パネル・下部ボタンを非表示にし、画面を広く使う */
body.create-tab-active {
  padding-bottom: 24px;
}

body.create-tab-active .top-container,
body.create-tab-active .water-amount-section,
body.create-tab-active .bottom-buttons {
  display: none !important;
}

body.create-tab-active .recipe-container {
  padding-left: 12px;
  padding-right: 12px;
  padding-bottom: 24px;
  overflow-x: visible;
}

body.create-tab-active #recipe-group-create {
  width: 100%;
  min-width: 100%;
}

.create-recipe-card {
  width: 100%;
  min-width: 0;
  max-width: 100%;
  margin: 0;
  padding: 18px 16px;
  box-sizing: border-box;
  text-align: left;
}

.create-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
  padding: 0 2px;
}

.create-section-label {
  font-size: 14px;
  font-weight: 700;
  color: #fbbf24;
}

.create-option-badge {
  background: #c98a4b;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  letter-spacing: 0.3px;
}

/* 4つの作成方法メニューリスト */
.create-menu-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.create-menu-item {
  width: 100%;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid #3f3f46;
  border-radius: 12px;
  padding: 14px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  text-align: left;
  transition: all 0.2s ease;
  box-sizing: border-box;
}

.create-menu-item:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: #6b7280;
}

.create-menu-item:active {
  transform: scale(0.985);
}

.create-menu-icon {
  width: 40px;
  height: 40px;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.07);
  color: #e5e7eb;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.create-menu-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.create-menu-title-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 6px;
  width: 100%;
}

.create-menu-title {
  color: #f3f4f6;
  font-size: 14.5px;
  font-weight: 700;
  line-height: 1.3;
  margin-right: auto;
}

.create-beta-badge {
  font-size: 10.5px;
  font-weight: 600;
  color: #d1d5db;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid #3f3f46;
  padding: 2px 5px;
  border-radius: 4px;
  line-height: 1.25;
  white-space: nowrap;
  flex-shrink: 0;
}

.create-login-badge {
  font-size: 10.5px;
  font-weight: 600;
  color: #fbbf24;
  background: rgba(245, 158, 11, 0.14);
  border: 1px solid rgba(245, 158, 11, 0.4);
  padding: 2px 5px;
  border-radius: 4px;
  line-height: 1.25;
  white-space: nowrap;
  flex-shrink: 0;
}

.create-beta-note {
  margin: 12px 2px 0;
  font-size: 12.5px;
  color: #9ca3af;
  line-height: 1.5;
}

.create-menu-desc {
  color: #9ca3af;
  font-size: 13px;
  line-height: 1.4;
}

.create-menu-arrow {
  color: #9ca3af;
  font-size: 22px;
  font-weight: 400;
  line-height: 1;
  flex-shrink: 0;
}

/* 「または」の区切り線 */
.create-divider {
  display: flex;
  align-items: center;
  text-align: center;
  margin: 12px 0;
  color: #6b7280;
  font-size: 12px;
  font-weight: 600;
}

.create-divider::before,
.create-divider::after {
  content: "";
  flex: 1;
  border-bottom: 1px solid #2d3748;
}

.create-divider span {
  padding: 0 10px;
  letter-spacing: 0.5px;
}

/* ステップ2: 各方法の生成画面 */
.create-back-btn {
  background: transparent;
  border: none;
  color: #d1d5db;
  font-size: 14px;
  font-weight: 600;
  padding: 2px 0 14px 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color 0.15s;
}

.create-back-btn:hover {
  color: #f3f4f6;
}

.create-back-btn span {
  font-size: 19px;
  line-height: 1;
}

.create-mode-pane {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid #27272a;
  border-radius: 12px;
  padding: 16px;
  box-sizing: border-box;
}

.create-pane-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.create-pane-icon {
  color: #e5e7eb;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.create-pane-title {
  margin: 0;
  color: #f3f4f6;
  font-size: 16.5px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.create-pane-desc {
  color: #d1d5db;
  font-size: 14px;
  line-height: 1.5;
  margin: 0 0 14px 0;
}

.ai-input-full {
  width: 100%;
  margin-bottom: 12px;
  display: block;
}

.ai-generator-textarea {
  width: 100%;
  background: #09090b;
  border: 1px solid #3f3f46;
  color: #f3f4f6;
  padding: 12px 14px;
  border-radius: 10px;
  font-size: 15px;
  line-height: 1.55;
  resize: vertical;
  outline: none;
  font-family: inherit;
  box-sizing: border-box;
  transition: border-color 0.2s, box-shadow 0.2s;
  margin-bottom: 12px;
  display: block;
}

.ai-generator-textarea:focus {
  border-color: #c98a4b;
  box-shadow: 0 0 0 2px rgba(201, 138, 75, 0.25);
}

.ai-btn-full {
  width: 100%;
  justify-content: center;
  padding: 13px 16px;
  font-size: 15.5px;
  box-sizing: border-box;
}

.ai-image-dropzone-btn {
  width: 100%;
  padding: 24px 16px;
  background: rgba(201, 138, 75, 0.1);
  border: 1.5px dashed rgba(201, 138, 75, 0.55);
  color: #fbbf24;
  font-size: 14.5px;
  font-weight: 700;
  border-radius: 10px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s ease;
  box-sizing: border-box;
}

.ai-image-dropzone-btn:hover {
  background: rgba(201, 138, 75, 0.18);
  border-color: #fbbf24;
}

.ai-image-dropzone-btn:active {
  transform: scale(0.985);
}

.ai-image-dropzone-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.ai-image-dropzone-btn .btn-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.dropzone-icon {
  font-size: 28px;
  line-height: 1;
}

.ai-generator-card {
  max-width: 380px;
  margin: 0 auto 16px;
  background: #18181b;
  border: 1px solid #27272a;
  border-radius: 14px;
  padding: 16px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
  box-sizing: border-box;
}

.ai-generator-header {
  margin-bottom: 12px;
}

.ai-generator-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

.ai-generator-badge {
  background: linear-gradient(135deg, #c98a4b, #f59e0b);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 6px;
  letter-spacing: 0.5px;
}

.ai-generator-title {
  color: #f3f4f6;
  font-size: 16px;
  font-weight: 700;
}

.ai-generator-desc {
  color: #9ca3af;
  font-size: 14px;
  line-height: 1.5;
  margin: 0;
}

.ai-generator-input-wrapper {
  display: flex;
  gap: 8px;
  align-items: center;
}

.ai-generator-input {
  flex: 1;
  background: #09090b;
  border: 1px solid #3f3f46;
  color: #f3f4f6;
  padding: 12px 14px;
  border-radius: 10px;
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  box-sizing: border-box;
}

.ai-generator-input:focus {
  border-color: #c98a4b;
  box-shadow: 0 0 0 2px rgba(201, 138, 75, 0.25);
}

.ai-generator-btn {
  background: #c98a4b;
  color: #fff;
  border: none;
  padding: 12px 18px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: background 0.2s, transform 0.1s;
}

.ai-generator-btn:hover {
  background: #b57a3e;
}

.ai-generator-btn:active {
  transform: scale(0.98);
}

.ai-generator-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.ai-generator-status {
  margin-top: 12px;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 14px;
  line-height: 1.5;
  overflow-wrap: anywhere;
  word-break: break-word;
  box-sizing: border-box;
}

.ai-generator-status.loading {
  background: rgba(201, 138, 75, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(201, 138, 75, 0.3);
}

.ai-generator-status.error {
  background: rgba(239, 68, 68, 0.15);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.ai-generator-status.success {
  background: rgba(34, 197, 94, 0.15);
  color: #86efac;
  border: 1px solid rgba(34, 197, 94, 0.3);
}

.ai-generator-result {
  margin-top: 16px;
  padding: 16px;
  background: #09090b;
  border: 1px solid #3f3f46;
  border-radius: 12px;
}

.ai-result-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.ai-result-title {
  margin: 0;
  color: #fbbf24;
  font-size: 17.5px;
  font-weight: 700;
}

.ai-result-badge {
  background: rgba(34, 197, 94, 0.2);
  color: #4ade80;
  border: 1px solid rgba(34, 197, 94, 0.3);
  font-size: 12px;
  padding: 2px 6px;
  border-radius: 4px;
}

.ai-result-desc {
  color: #d1d5db;
  font-size: 14px;
  line-height: 1.55;
  margin: 0 0 12px 0;
}

.ai-result-meta {
  display: flex;
  gap: 8px;
  background: #18181b;
  padding: 12px;
  border-radius: 8px;
  margin-bottom: 12px;
}

.ai-result-meta-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  font-size: 13px;
  color: #9ca3af;
  text-align: center;
}

.ai-result-meta-item .meta-label {
  font-size: 12.5px;
  color: #9ca3af;
  line-height: 1.2;
}

.ai-result-meta-item .meta-value {
  color: #f3f4f6;
  font-size: 14.5px;
  line-height: 1.2;
  white-space: nowrap;
}

.ai-result-meta-item strong {
  color: #f3f4f6;
  font-size: 17px;
  font-weight: 700;
  margin-right: 1px;
}

.ai-result-memo {
  font-size: 13.5px;
  color: #e5e7eb;
  background: rgba(201, 138, 75, 0.08);
  border-left: 3px solid #c98a4b;
  padding: 8px 12px;
  border-radius: 0 6px 6px 0;
  margin-bottom: 14px;
  line-height: 1.5;
}

.ai-result-steps-section h5 {
  margin: 0 0 8px 0;
  color: #9ca3af;
  font-size: 13.5px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.ai-result-steps-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

.ai-result-step-row {
  display: flex;
  align-items: center;
  background: #18181b;
  border: 1px solid #27272a;
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 14.5px;
  gap: 10px;
}

.ai-result-step-time {
  color: #fbbf24;
  font-weight: 700;
  min-width: 42px;
  font-variant-numeric: tabular-nums;
}

.ai-result-step-weight {
  color: #60a5fa;
  font-weight: 600;
  min-width: 52px;
}

.ai-result-step-desc {
  color: #e5e7eb;
  flex: 1;
  line-height: 1.45;
}

.ai-result-actions {
  display: flex;
  gap: 8px;
  align-items: stretch;
}

.ai-result-apply-btn {
  flex: 1;
  background: #28a745;
  color: #fff;
  border: none;
  padding: 11px 14px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
}

.ai-result-apply-btn:hover {
  background: #218838;
}

.ai-result-edit-btn {
  flex: 1;
  background: #27272a;
  color: #e5e7eb;
  border: 1px solid #3f3f46;
  padding: 11px 14px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
}

.ai-result-edit-btn:hover {
  background: #3f3f46;
  color: #fff;
}

.ai-result-clear-btn {
  background: transparent;
  color: #9ca3af;
  border: 1px solid #3f3f46;
  padding: 11px 14px;
  min-width: 44px;
  border-radius: 8px;
  font-size: 15px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.ai-result-clear-btn:hover {
  background: #27272a;
  color: #fff;
}

/* ==============================================================================
   共通: 過去の記録から選ぶカード & 写真・パッケージ自動解析囲みボックス
   (記録画面・タイマー保存モーダル共通スタイル)
   ============================================================================== */
.edit-saved-beans-picker {
  background: rgba(245, 158, 11, 0.06);
  border: 1px solid rgba(245, 158, 11, 0.22);
  border-radius: 8px;
  padding: 8px 10px;
  margin-bottom: 14px;
}

.saved-bean-candidate-card {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 9px 11px;
  background: #1c1917;
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: 10px;
  color: #f3f4f6;
  cursor: pointer;
  flex-shrink: 0;
  width: 152px;
  text-align: left;
  transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}
@media (hover: hover) and (pointer: fine) {
  .saved-bean-candidate-card:hover:not(.is-selected) {
    background: rgba(245, 158, 11, 0.12);
    border-color: rgba(251, 191, 36, 0.7);
  }
}
.saved-bean-candidate-card.is-selected {
  background: rgba(245, 158, 11, 0.22);
  border-color: #fbbf24;
  box-shadow: 0 0 0 1px rgba(251, 191, 36, 0.45), 0 2px 8px rgba(245, 158, 11, 0.25);
}
.saved-bean-candidate-roaster {
  font-size: 10px;
  color: #fbbf24;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.saved-bean-candidate-name {
  font-size: 12.5px;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.saved-bean-candidate-badge {
  font-size: 9.5px;
  padding: 1px 6px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 4px;
  color: #d1d5db;
}

/* 写真・パッケージ自動解析エリア囲み (破線ボーダー枠) */
.record-photo-upload-box {
  background: #161616;
  border: 1.5px dashed rgba(255, 255, 255, 0.16);
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 14px;
  box-sizing: border-box;
}
.record-photo-upload-box .ai-parse-trigger-btn {
  margin-bottom: 0 !important;
}

.edit-photo-capture-btn,
.edit-photo-upload-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex: 1;
  padding: 10px 8px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px dashed #444;
  border-radius: 8px;
  color: white;
  cursor: pointer;
  gap: 4px;
  transition: all 0.15s ease;
}
.edit-photo-capture-btn:hover,
.edit-photo-upload-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: #777;
}

.record-bean-sync-hint {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: #9ca3af;
  margin-top: 6px;
  line-height: 1.4;
}

/* クラフトテーマ対応 */
[data-theme="craft"] .edit-saved-beans-picker {
  background: var(--mame-amber-pale, rgba(201, 138, 75, 0.1)) !important;
  border-color: rgba(201, 138, 75, 0.35) !important;
}
[data-theme="craft"] .saved-bean-candidate-card {
  background: #FFFFFF !important;
  border: 1px solid var(--mame-border, #DFD0BE) !important;
  color: var(--mame-roast-dark, #2B211E) !important;
  box-shadow: 0 2px 5px rgba(43, 33, 30, 0.06) !important;
}
@media (hover: hover) and (pointer: fine) {
  [data-theme="craft"] .saved-bean-candidate-card:hover:not(.is-selected) {
    background: #FFFDF9 !important;
    border-color: var(--mame-amber, #C98A4B) !important;
  }
}
[data-theme="craft"] .saved-bean-candidate-card.is-selected {
  background: rgba(201, 138, 75, 0.18) !important;
  border-color: var(--mame-amber, #C98A4B) !important;
  box-shadow: 0 0 0 1px rgba(201, 138, 75, 0.45), 0 2px 8px rgba(201, 138, 75, 0.2) !important;
}
[data-theme="craft"] .saved-bean-candidate-roaster {
  color: var(--mame-amber, #C98A4B) !important;
}
[data-theme="craft"] .saved-bean-candidate-name {
  color: var(--mame-roast-dark, #2B211E) !important;
}
[data-theme="craft"] .saved-bean-candidate-badge {
  background: var(--mame-paper, #F7F3ED) !important;
  border: 1px solid var(--mame-border, #DFD0BE) !important;
  color: var(--mame-roast-medium, #6E564C) !important;
}
[data-theme="craft"] .record-photo-upload-box {
  background: #FFFFFF !important;
  border: 1.5px dashed var(--mame-border, #DFD0BE) !important;
}
[data-theme="craft"] .edit-photo-capture-btn,
[data-theme="craft"] .edit-photo-upload-btn {
  background: var(--mame-paper, #F7F3ED) !important;
  border: 1px dashed var(--mame-border, #DFD0BE) !important;
  color: var(--mame-roast-dark, #2B211E) !important;
}
[data-theme="craft"] .edit-photo-capture-btn:hover,
[data-theme="craft"] .edit-photo-upload-btn:hover {
  background: var(--mame-amber-pale, rgba(201, 138, 75, 0.1)) !important;
  border-color: var(--mame-amber, #C98A4B) !important;
  color: var(--mame-amber, #C98A4B) !important;
}
[data-theme="craft"] .ai-parse-trigger-btn {
  background: var(--mame-amber-pale, rgba(201, 138, 75, 0.1)) !important;
  border-color: var(--mame-amber, #C98A4B) !important;
  color: var(--mame-roast-dark, #2B211E) !important;
}
[data-theme="craft"] .record-bean-sync-hint {
  color: var(--mame-roast-medium, #6E564C) !important;
}

/* Accessibility & SEO utility for hidden headings */
.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* ===================================================
   Today's Brew Card & Drip Completion Screen Styles
   =================================================== */

.drip-complete-banner {
  position: relative;
  width: 100%;
  max-width: 440px;
  margin: 0 auto 16px;
  padding: 0 16px;
  box-sizing: border-box;
  animation: dripBannerFadeIn 0.35s ease;
}

.drip-complete-banner-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.16), rgba(30, 27, 24, 0.95));
  border: 1px solid rgba(245, 158, 11, 0.4);
  border-radius: 14px;
  padding: 10px 14px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
}

.drip-complete-banner-icon {
  font-size: 26px;
  line-height: 1;
}

.drip-complete-banner-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
  text-align: left;
}

.drip-complete-banner-text strong {
  font-size: 14px;
  color: #ffffff;
  font-weight: 700;
}

.drip-complete-banner-text span {
  font-size: 11.5px;
  color: #fbbf24;
}

.drip-complete-banner-btn {
  background: #f59e0b;
  color: #000000;
  border: none;
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.15s, background 0.2s, box-shadow 0.2s;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
}

.drip-complete-banner-btn:hover {
  background: #fbbf24;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.45);
}

.drip-complete-banner-btn:active {
  transform: scale(0.96);
}

.share-to-x-btn:hover {
  background: #111111 !important;
  border-color: rgba(255, 255, 255, 0.4) !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
}

.record-modal__share-card-btn:hover {
  background: rgba(245, 158, 11, 0.2) !important;
  border-color: #f59e0b !important;
}

@keyframes dripBannerFadeIn {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* =========================================================
   PWA Install Prompt (Routine & Habit Layer)
   抽出完了時に控えめに案内し、タイマー計測画面は絶対に散らかさない
   ========================================================= */
.coffee-pwa-install-prompt {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(30px);
  max-width: 440px;
  width: calc(100% - 32px);
  background: rgba(28, 25, 23, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4), 0 0 1px rgba(255, 255, 255, 0.1);
  padding: 14px 18px;
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-sizing: border-box;
}

[data-theme="craft"] .coffee-pwa-install-prompt {
  background: rgba(253, 251, 247, 0.96);
  border: 1px solid var(--mame-border, #EADBCE);
  box-shadow: 0 10px 30px rgba(43, 33, 30, 0.15);
}

.coffee-pwa-install-prompt.pwa-prompt-show {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

.coffee-pwa-prompt-inner {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.coffee-pwa-prompt-header {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.coffee-pwa-prompt-icon {
  font-size: 26px;
  line-height: 1;
  flex-shrink: 0;
  padding-top: 2px;
}

.coffee-pwa-prompt-texts {
  flex: 1;
}

.coffee-pwa-prompt-title {
  font-size: 14.5px;
  font-weight: 700;
  color: #F3F4F6;
  margin-bottom: 4px;
}

[data-theme="craft"] .coffee-pwa-prompt-title {
  color: var(--mame-roast-dark, #2B211E);
}

.coffee-pwa-prompt-desc {
  font-size: 12.5px;
  line-height: 1.45;
  color: #9CA3AF;
}

[data-theme="craft"] .coffee-pwa-prompt-desc {
  color: var(--mame-roast-medium, #5C443C);
}

.coffee-pwa-prompt-ios-hint {
  font-size: 11.5px;
  line-height: 1.4;
  color: #FBBF24;
  margin-top: 6px;
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}

[data-theme="craft"] .coffee-pwa-prompt-ios-hint {
  color: var(--mame-terracotta, #C86446);
}

.coffee-pwa-prompt-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.coffee-pwa-btn-install {
  background: #C98A4B;
  color: #FFFFFF;
  border: none;
  border-radius: 10px;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.coffee-pwa-btn-install:hover {
  background: #B37537;
  transform: translateY(-1px);
}

.coffee-pwa-btn-later {
  background: transparent;
  color: #9CA3AF;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 12.5px;
  cursor: pointer;
  transition: all 0.2s ease;
}

[data-theme="craft"] .coffee-pwa-btn-later {
  color: var(--mame-roast-light, #8C746B);
  border-color: var(--mame-border, #EADBCE);
}

.coffee-pwa-btn-later:hover {
  color: #E5E7EB;
  background: rgba(255, 255, 255, 0.05);
}

[data-theme="craft"] .coffee-pwa-btn-later:hover {
  color: var(--mame-roast-dark, #2B211E);
  background: rgba(0, 0, 0, 0.03);
}

/* ==========================================================================
   Brew Pad & Recipe Sheet (Adaptive Context UI)
   ========================================================================== */

/* --- 1. Brew Pad: Active Recipe Selector Pill --- */
.active-recipe-trigger-wrapper {
  display: flex;
  justify-content: center;
  margin-top: 6px;
}

.active-recipe-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #f3f4f6;
  padding: 8px 16px;
  border-radius: 9999px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  max-width: 90%;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.active-recipe-pill:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(201, 138, 75, 0.6);
  transform: translateY(-1px);
}

.active-recipe-pill:active {
  transform: scale(0.98);
}

.active-recipe-pill__icon {
  font-size: 16px;
  line-height: 1;
}

.active-recipe-pill__title {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 220px;
}

.active-recipe-pill__chevron {
  font-size: 12px;
  color: #c98a4b;
  font-weight: 700;
  padding: 2px 7px;
  background: rgba(201, 138, 75, 0.15);
  border-radius: 6px;
}

[data-theme="craft"] .active-recipe-pill {
  background: #EFE7DC;
  border-color: #DBC8B2;
  color: #2B211E;
}

[data-theme="craft"] .active-recipe-pill:hover {
  background: #E5DBD0;
}

[data-theme="craft"] .active-recipe-pill__chevron {
  background: rgba(43, 33, 30, 0.08);
  color: #8C673D;
}

/* --- 2. Brew Pad: Step Guide & Visual Timeline --- */
.step-guide-section {
  max-width: 440px;
  margin: 14px auto 10px;
  padding: 0 16px;
  box-sizing: border-box;
}

.current-step-callout {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  padding: 12px 18px;
  transition: all 0.25s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.current-step-callout.approaching {
  border-color: #fbbf24;
  background: rgba(251, 191, 36, 0.12);
  box-shadow: 0 0 16px rgba(251, 191, 36, 0.3);
  animation: stepPulse 1s infinite alternate;
}

@keyframes stepPulse {
  0% { transform: scale(1); }
  100% { transform: scale(1.02); }
}

.current-step-badge {
  background: #c98a4b;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 6px;
  white-space: nowrap;
  letter-spacing: 0.02em;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.current-step-instruction {
  font-size: 15px;
  font-weight: 600;
  color: #ffffff;
  text-align: left;
  line-height: 1.4;
}

[data-theme="craft"] .current-step-callout {
  background: #FAF7F0;
  border-color: #DBC8B2;
  box-shadow: 0 2px 6px rgba(43, 33, 30, 0.08);
}

[data-theme="craft"] .current-step-instruction {
  color: #2B211E;
}

[data-theme="craft"] .current-step-badge {
  background: #8C673D;
}

/* タイムライン進行バー & チップ */
.step-timeline-container {
  margin-top: 10px;
}

.step-timeline-progress-track {
  width: 100%;
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
  margin-bottom: 8px;
}

[data-theme="craft"] .step-timeline-progress-track {
  background: #EADBCE;
}

.step-timeline-progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #c98a4b, #fbbf24);
  transition: width 0.15s linear;
}

.brewpad-step-chips {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 2px 0 4px;
  scrollbar-width: none;
  justify-content: center;
  flex-wrap: wrap;
}

.brewpad-step-chips::-webkit-scrollbar {
  display: none;
}

.brewpad-step-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 4px 8px;
  font-size: 11.5px;
  color: #9ca3af;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.brewpad-step-chip.active {
  background: rgba(201, 138, 75, 0.25);
  border-color: #c98a4b;
  color: #fff;
  font-weight: 700;
}

.brewpad-step-chip.done {
  opacity: 0.45;
}

[data-theme="craft"] .brewpad-step-chip {
  background: #EFE7DC;
  border-color: #DBC8B2;
  color: #6E564C;
}

[data-theme="craft"] .brewpad-step-chip.active {
  background: #2B211E;
  color: #FAF7F0;
  border-color: #2B211E;
}

/* --- 3. Recipe Sheet (Bottom Sheet & Desktop Modal) --- */
.recipe-bottom-sheet-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.recipe-bottom-sheet-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

.recipe-bottom-sheet {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 85vh;
  max-height: 85vh;
  background: #141414;
  border-radius: 24px 24px 0 0;
  box-shadow: 0 -8px 36px rgba(0, 0, 0, 0.8);
  z-index: 1000;
  transform: translateY(105%);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  box-sizing: border-box;
  overflow: hidden;
}

.recipe-bottom-sheet.open {
  transform: translateY(0);
}

@media (min-width: 768px) {
  .recipe-bottom-sheet {
    top: 50%;
    left: 50%;
    bottom: auto;
    right: auto;
    width: 90%;
    max-width: 600px;
    height: 80vh;
    border-radius: 20px;
    transform: translate(-50%, -45%) scale(0.95);
    border: 1px solid rgba(255, 255, 255, 0.15);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease;
  }
  .recipe-bottom-sheet.open {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
    pointer-events: auto;
  }
}

.recipe-sheet__handle {
  width: 44px;
  height: 5px;
  background: #4b5563;
  border-radius: 9999px;
  margin: 10px auto 4px;
}

.recipe-sheet__header {
  padding: 8px 18px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  flex-shrink: 0;
}

.recipe-sheet__title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.recipe-sheet__title {
  font-size: 18px;
  font-weight: 700;
  margin: 0;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 6px;
}

.recipe-sheet__close-btn {
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: #9ca3af;
  font-size: 18px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.recipe-sheet__close-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.recipe-sheet__body {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 12px 14px 40px;
}

/* レシピシート内のカード配置 */
.recipe-sheet__body .recipe-container {
  max-width: 100%;
  padding-left: 0;
  padding-right: 0;
  padding-bottom: 40px;
}

.recipe-sheet__body .recipe-card {
  width: 320px;
  min-width: 300px;
}

/* レシピカード内の「このレシピで淹れる」ボタン */
.btn-select-recipe-card {
  width: 100%;
  background: #c98a4b;
  color: #ffffff;
  border: none;
  border-radius: 10px;
  padding: 11px 16px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  margin-top: 14px;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  box-shadow: 0 4px 12px rgba(201, 138, 75, 0.3);
}

.btn-select-recipe-card:hover {
  background: #b37537;
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(201, 138, 75, 0.45);
}

.btn-select-recipe-card:active {
  transform: scale(0.98);
}

.recipe-card.active-recipe {
  /* active-recipe はカルーセル中央スナップで判別されるため枠線は不要。ピン留め（is-pinned）の琥珀枠線と競合しないよう境界線を排す */
  border: none;
}

/* --- 4. クラフトテーマ適応 --- */
[data-theme="craft"] .recipe-bottom-sheet {
  background: #FAF7F0;
  border-top-color: #DBC8B2;
  box-shadow: 0 -8px 36px rgba(43, 33, 30, 0.25);
}

[data-theme="craft"] .recipe-sheet__handle {
  background: #C7B7A3;
}

[data-theme="craft"] .recipe-sheet__header {
  border-bottom-color: #DBC8B2;
}

[data-theme="craft"] .recipe-sheet__title {
  color: #2B211E;
}

[data-theme="craft"] .recipe-sheet__close-btn {
  background: #EFE7DC;
  color: #6E564C;
}

[data-theme="craft"] .btn-select-recipe-card {
  background: #8C673D;
  box-shadow: 0 4px 12px rgba(140, 103, 61, 0.3);
}

/* --- 5. 抽出中（timer-active）のミニマリズム --- */
body.timer-active .active-recipe-trigger-wrapper {
  opacity: 0.6;
  pointer-events: none;
}

body.timer-active .recipe-bottom-sheet,
body.timer-active .recipe-bottom-sheet-backdrop {
  display: none !important;
}

/* ==========================================================================
   PWA Notification Slide-in Banner (画面上部からスライドインする通知型バナー)
   ========================================================================== */
.coffee-pwa-slide-banner {
  position: fixed;
  top: 14px;
  left: 14px;
  right: 14px;
  max-width: 440px;
  margin: 0 auto;
  z-index: 999999;
  transform: translateY(-140%);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease;
  box-sizing: border-box;
  text-align: left;
}

.coffee-pwa-slide-banner.show {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.pwa-slide-banner-inner {
  position: relative;
  background: rgba(26, 19, 15, 0.97);
  border: 1px solid rgba(245, 158, 11, 0.5);
  border-radius: 16px;
  padding: 16px 18px;
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.55), 0 0 16px rgba(245, 158, 11, 0.15);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-sizing: border-box;
}

.pwa-slide-banner-close {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  color: #b8aba3;
  font-size: 26px;
  cursor: pointer;
  padding: 0;
  line-height: 1;
  transition: color 0.15s;
}

.pwa-slide-banner-close:hover {
  color: #ffffff;
}

.pwa-slide-banner-status {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-right: 36px;
  font-size: 17px;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.3;
}

.pwa-slide-status-icon {
  font-size: 19px;
  line-height: 1;
  flex-shrink: 0;
}

.pwa-slide-banner-divider {
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  margin: 11px 0;
}

.pwa-slide-banner-benefit {
  display: flex;
  flex-direction: column;
}

.pwa-slide-banner-title {
  font-size: 15.5px;
  font-weight: 700;
  color: #fef3c7;
  margin-bottom: 4px;
  line-height: 1.38;
}

.pwa-slide-banner-desc {
  font-size: 13.5px;
  color: #e5e7eb;
  line-height: 1.48;
}

.pwa-slide-banner-steps {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 12px;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(245, 158, 11, 0.28);
  border-radius: 12px;
  padding: 11px 14px;
  font-size: 15px;
  line-height: 1.5;
}

.pwa-slide-step-item {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #f3f4f6;
}

.pwa-os-badge {
  background: rgba(245, 158, 11, 0.25);
  color: #fbbf24;
  font-size: 13px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 6px;
  border: 1px solid rgba(245, 158, 11, 0.45);
  flex-shrink: 0;
  letter-spacing: 0.3px;
}

.pwa-step-detail {
  flex: 1;
  font-size: 15px;
  color: #f3f4f6;
}

.pwa-step-detail strong {
  color: #ffffff;
  font-weight: 700;
}

/* スライドインバナーのフッター（しばらく表示しない ＆ 閉じる） */
.pwa-slide-banner-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 13px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  gap: 12px;
}

.pwa-dont-show-label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #9ca3af;
  cursor: pointer;
  user-select: none;
  font-size: 13px;
  line-height: 1.2;
  transition: color 0.15s ease;
}

.pwa-dont-show-label:hover {
  color: #e5e7eb;
}

.pwa-dont-show-checkbox {
  width: 17px;
  height: 17px;
  cursor: pointer;
  accent-color: #c98a4b;
  border-radius: 4px;
  margin: 0;
}

.pwa-footer-close-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #e5e7eb;
  padding: 6px 16px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.pwa-footer-close-btn:hover {
  background: rgba(255, 255, 255, 0.16);
  color: #ffffff;
}

.btn-pwa-install-action {
  background: var(--mame-amber, #c98a4b);
  color: #ffffff !important;
  border: none;
  border-radius: 8px;
  padding: 7px 14px;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(201, 138, 75, 0.25);
  transition: all 0.15s ease;
}

.btn-pwa-install-action:hover {
  background: #b37537;
  transform: translateY(-1px);
}

/* ガイドモーダル */
.coffee-pwa-guide-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  box-sizing: border-box;
}

.coffee-pwa-guide-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
}

.coffee-pwa-guide-content {
  position: relative;
  background: var(--mame-paper, #FAF7F0);
  border: 1px solid var(--mame-border, #EADBCE);
  border-radius: 16px;
  padding: 20px;
  max-width: 400px;
  width: 100%;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.25);
  box-sizing: border-box;
  animation: modalPopIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

[data-theme="dark"] .coffee-pwa-guide-content {
  background: #1a1a1a;
  border-color: rgba(255, 255, 255, 0.15);
}

.coffee-pwa-guide-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.coffee-pwa-guide-close {
  background: none;
  border: none;
  font-size: 24px;
  color: var(--mame-roast-medium, #5c443c);
  cursor: pointer;
  padding: 0 4px;
  line-height: 1;
}

/* 軽量保存完了トースト（PWAバナー非表示時に自動表示） */
.coffee-saved-toast {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(-25px);
  z-index: 9999999;
  background: rgba(28, 20, 16, 0.94);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #fdfbf7;
  font-size: 14px;
  font-weight: 600;
  padding: 10px 22px;
  border-radius: 30px;
  border: 1px solid rgba(201, 138, 75, 0.45);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.32), 0 2px 6px rgba(201, 138, 75, 0.2);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1), transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.coffee-saved-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}

.coffee-saved-toast.hide {
  opacity: 0;
  transform: translateX(-50%) translateY(-15px);
  pointer-events: none;
}

/* =========================================================
   軽量記録モーダル（かんたん記録 / 詳しく記録 2タブ & 味チップ）
   ========================================================= */
/* かんたん記録 ⇄ 詳しく記録 の切替でモーダル上端の位置を完全固定 */
#record-modal {
  align-items: flex-start;
  padding-top: max(20px, env(safe-area-inset-top, 20px));
  padding-bottom: max(20px, env(safe-area-inset-bottom, 20px));
}

#record-modal .record-modal__content--compact {
  padding: 20px 20px 18px;
  max-width: 420px;
  margin: 0 auto;
  max-height: calc(100vh - 40px);
  max-height: calc(100dvh - 40px);
}

.record-modal__title--compact {
  font-size: 18px;
  margin: 0 0 12px 0;
  text-align: left;
}

.record-mode-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  border-bottom: 2px solid rgba(255, 255, 255, 0.16);
  padding: 0 2px;
  margin-bottom: 14px;
}

.record-mode-tab {
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-bottom: none;
  background: rgba(255, 255, 255, 0.05);
  color: #cbd5e1;
  font-size: 13.5px;
  font-weight: 600;
  padding: 10px 8px 9px;
  border-radius: 10px 10px 0 0;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
  margin-bottom: -2px;
  border-bottom: 2px solid transparent;
  -webkit-tap-highlight-color: transparent;
}

@media (hover: hover) and (pointer: fine) {
  .record-mode-tab:hover:not(.active) {
    background: rgba(255, 255, 255, 0.1);
    color: #f9fafb;
  }
}

.record-mode-tab.active {
  background: rgba(245, 158, 11, 0.18);
  border-color: rgba(251, 191, 36, 0.48);
  border-bottom: 3px solid #f59e0b;
  color: #fef3c7;
  font-weight: 800;
  box-shadow: 0 -2px 10px rgba(245, 158, 11, 0.14);
}

.record-summary-pill {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.28);
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 13px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}

.record-summary-pill__left {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  flex: 1 1 auto;
}

.record-summary-pill__title {
  font-size: 13.5px;
  font-weight: 700;
  color: #fbbf24;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.record-summary-pill__meta {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #d1d5db;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
}

.record-summary-pill__meta strong {
  color: #f9fafb;
  font-weight: 700;
}

.record-summary-pill__sep {
  opacity: 0.55;
}

.record-summary-pill__water {
  color: #9ca3af;
  font-weight: 500;
}

.record-segment-nudge {
  font-size: 12px;
  line-height: 1.45;
  color: #e5e7eb;
  background: rgba(255, 255, 255, 0.04);
  border-left: 3px solid #d97706;
  padding: 6px 10px;
  border-radius: 0 8px 8px 0;
  margin-bottom: 12px;
}

.record-modal__field--compact {
  margin-bottom: 12px;
  gap: 5px;
}

.record-field-label-center {
  text-align: center;
  font-size: 12px !important;
  font-weight: 700 !important;
  color: #9ca3af !important;
}

.star-rating--compact {
  font-size: 32px;
  justify-content: center;
  gap: 10px;
  padding: 2px 0 4px;
}

.record-taste-chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
}

.record-taste-chip {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #e5e7eb;
  font-size: 12.5px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.12s ease, border-color 0.12s ease, color 0.12s ease, transform 0.1s ease;
  line-height: 1.2;
  -webkit-tap-highlight-color: transparent;
  outline: none;
}

.record-taste-chip:active {
  transform: scale(0.96);
}

@media (hover: hover) and (pointer: fine) {
  .record-taste-chip:hover:not(.selected) {
    border-color: rgba(251, 191, 36, 0.55);
    color: #fef3c7;
  }
}

.record-taste-chip.selected {
  background: rgba(245, 158, 11, 0.26);
  border-color: #fbbf24;
  color: #fef3c7;
}

.record-brew-params-row {
  display: grid;
  grid-template-columns: 1fr 1.45fr;
  gap: 10px;
  margin-bottom: 14px;
}

.record-brew-param-field label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  color: #ccc;
  margin-bottom: 4px;
}

.record-brew-param-field input {
  width: 100%;
  height: auto;
  padding: 9px 11px;
  background: #222;
  border: 1px solid #444;
  color: #fff;
  border-radius: 8px;
  font-size: 14px;
  box-sizing: border-box;
}

.record-brew-param-field input:focus {
  border-color: #f59e0b;
  outline: none;
}

.record-modal__textarea--compact {
  padding: 10px 12px;
  border-radius: 10px;
  min-height: 44px;
}

.record-detailed-section {
  margin-top: 4px;
  margin-bottom: 6px;
}

.record-modal__actions--compact {
  margin-top: 14px;
  gap: 10px;
}

.record-modal__actions--compact .record-modal__cancel {
  flex: 0 0 auto;
  padding: 12px 14px;
  font-size: 14px;
}

.record-modal__actions--compact .record-modal__save {
  flex: 1;
  padding: 12px 14px;
  font-size: 14.5px;
  font-weight: 700;
  background: linear-gradient(135deg, #d97706, #b45309);
  white-space: normal;
  line-height: 1.25;
}

.record-guest-footnote {
  margin-top: 10px;
  text-align: center;
  font-size: 11.5px;
  color: #9ca3af;
  line-height: 1.4;
}

.record-guest-login-link {
  background: none;
  border: none;
  padding: 0;
  margin-left: 6px;
  color: #fbbf24;
  font-size: 11.5px;
  font-weight: 600;
  text-decoration: underline;
  cursor: pointer;
}

@media (hover: hover) and (pointer: fine) {
  .record-guest-login-link:hover {
    color: #fde68a;
  }
}

/* 全画面共通: モーダル表示中の背面スクロールロック */
html.modal-open,
body.modal-open {
  overflow: hidden !important;
  overscroll-behavior: none !important;
}

/* 全画面共通: インライン豆サジェスト候補（Craft / Dark 両対応） */
.inline-bean-suggestion-box {
  display: none;
  margin-top: 8px;
  padding: 10px 12px;
  background: rgba(245, 158, 11, 0.10);
  border: 1px dashed rgba(245, 158, 11, 0.45);
  border-radius: 10px;
}

.inline-bean-suggestion-box__title {
  font-size: 11.5px;
  font-weight: 700;
  color: #fbbf24;
  margin-bottom: 6px;
}

.inline-bean-suggestion-item {
  padding: 9px 11px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 10px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 13px;
  transition: background-color 0.15s ease, border-color 0.15s ease;
  margin-bottom: 4px;
}

.inline-bean-suggestion-item__main {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
}

.inline-bean-suggestion-item__thumb {
  width: 42px;
  height: 42px;
  border-radius: 6px;
  overflow: hidden;
  flex-shrink: 0;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.06);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}

.inline-bean-suggestion-item__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.inline-bean-suggestion-item__text {
  min-width: 0;
}

.inline-bean-suggestion-item__roaster {
  color: #fbbf24;
  font-size: 11.5px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.inline-bean-suggestion-item__name {
  color: #f3f4f6;
  font-size: 13.5px;
  font-weight: 700;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.inline-bean-suggestion-item__meta {
  color: #d1d5db;
  font-size: 11px;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.inline-bean-suggestion-item__badge {
  color: #fbbf24;
  font-size: 11.5px;
  font-weight: 700;
  background: rgba(245, 158, 11, 0.16);
  border: 1px solid rgba(245, 158, 11, 0.45);
  padding: 4px 9px;
  border-radius: 6px;
  white-space: nowrap;
  flex-shrink: 0;
}

@media (hover: hover) and (pointer: fine) {
  .inline-bean-suggestion-item:hover {
    background: rgba(245, 158, 11, 0.18);
    border-color: #fbbf24;
  }
}

[data-theme="craft"] .inline-bean-suggestion-box {
  background: var(--mame-amber-pale, #FBF3E8);
  border-color: var(--mame-amber, #C98A4B);
}

[data-theme="craft"] .inline-bean-suggestion-box__title {
  color: var(--mame-amber, #B86E2E);
}

[data-theme="craft"] .inline-bean-suggestion-item {
  background: #FFFFFF;
  border-color: var(--mame-border, #DFD0BE);
  box-shadow: 0 1px 4px rgba(43, 33, 30, 0.05);
}

[data-theme="craft"] .inline-bean-suggestion-item__thumb {
  border-color: var(--mame-border, #DFD0BE);
  background: var(--mame-paper, #F2EBE1);
}

[data-theme="craft"] .inline-bean-suggestion-item__roaster {
  color: var(--mame-amber, #B86E2E);
}

[data-theme="craft"] .inline-bean-suggestion-item__name {
  color: var(--mame-roast-dark, #2B211E);
}

[data-theme="craft"] .inline-bean-suggestion-item__meta {
  color: var(--mame-roast-medium, #6E564C);
}

[data-theme="craft"] .inline-bean-suggestion-item__badge {
  color: var(--mame-amber, #B86E2E);
  background: var(--mame-amber-pale, #FBF3E8);
  border-color: var(--mame-amber, #C98A4B);
}

@media (hover: hover) and (pointer: fine) {
  [data-theme="craft"] .inline-bean-suggestion-item:hover {
    background: var(--mame-amber-pale, #FBF3E8);
    border-color: var(--mame-amber, #C98A4B);
  }
}

/* クラフトテーマ対応 */
[data-theme="craft"] .record-mode-tabs {
  background: transparent;
  border-bottom-color: var(--mame-border, #DFD0BE);
}

[data-theme="craft"] .record-mode-tab {
  background: var(--mame-paper, #F2EBE1);
  border-color: var(--mame-border, #DFD0BE);
  color: var(--mame-roast-medium, #6E564C);
}

@media (hover: hover) and (pointer: fine) {
  [data-theme="craft"] .record-mode-tab:hover:not(.active) {
    background: #FAF6F0;
    color: var(--mame-roast-dark, #2B211E);
  }
}

[data-theme="craft"] .record-brew-param-field label {
  color: var(--mame-roast-medium, #5C443C);
}

[data-theme="craft"] .record-brew-param-field input {
  background: #FFFFFF;
  border-color: var(--mame-border, #DFD0BE);
  color: var(--mame-roast-dark, #2B211E);
}

[data-theme="craft"] .record-mode-tab.active {
  background: #FFFFFF;
  border-color: rgba(201, 138, 75, 0.5);
  border-bottom: 3px solid var(--mame-amber, #C98A4B);
  color: var(--mame-roast-dark, #2B211E);
  box-shadow: 0 -2px 8px rgba(43, 33, 30, 0.06);
}

[data-theme="craft"] .record-summary-pill {
  background: rgba(201, 138, 75, 0.12);
  border-color: rgba(201, 138, 75, 0.35);
}

[data-theme="craft"] .record-summary-pill__title {
  color: var(--mame-roast-dark, #2B211E);
}

[data-theme="craft"] .record-summary-pill__meta,
[data-theme="craft"] .record-summary-pill__meta strong,
[data-theme="craft"] .record-summary-pill__water {
  color: var(--mame-roast-medium, #5C443C);
}

[data-theme="craft"] .record-segment-nudge {
  color: var(--mame-roast-dark, #2B211E);
  background: rgba(201, 138, 75, 0.08);
  border-left-color: var(--mame-amber, #C98A4B);
}

[data-theme="craft"] .record-field-label-center {
  color: var(--mame-roast-medium, #6E564C) !important;
}

[data-theme="craft"] .record-taste-chip {
  background: #FFFFFF;
  border-color: var(--mame-border, #DFD0BE);
  color: var(--mame-roast-dark, #2B211E);
}

[data-theme="craft"] .record-taste-chip.selected {
  background: rgba(201, 138, 75, 0.18);
  border-color: var(--mame-amber, #C98A4B);
  color: var(--mame-roast-dark, #2B211E);
}

[data-theme="craft"] .record-guest-footnote {
  color: var(--mame-roast-medium, #6E564C);
}

[data-theme="craft"] .record-guest-login-link {
  color: var(--mame-amber, #B86E2E);
}

/* =========================================================
   全ページ共通 写真拡大ライトボックス & 過去写真サムネイル視認性改善
   ========================================================= */
.global-photo-lightbox {
  position: fixed;
  inset: 0;
  z-index: 10050;
  background: rgba(0, 0, 0, 0.94);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  opacity: 0;
  transition: opacity 0.2s ease;
  overflow: hidden;
}

.global-photo-lightbox.show {
  opacity: 1;
}

.global-photo-lightbox__slider {
  display: flex;
  width: 100%;
  height: 100%;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.global-photo-lightbox__slider::-webkit-scrollbar {
  display: none;
}

.global-photo-lightbox__slide {
  flex: 0 0 100%;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  scroll-snap-align: center;
  padding: 56px 16px 36px;
  box-sizing: border-box;
}

.global-photo-lightbox__slide img {
  max-width: 94vw;
  max-height: 84vh;
  border-radius: 10px;
  object-fit: contain;
  box-shadow: 0 10px 36px rgba(0, 0, 0, 0.65);
  transform: scale(0.96);
  transition: transform 0.2s ease;
}

.global-photo-lightbox.show .global-photo-lightbox__slide img {
  transform: scale(1);
}

.global-photo-lightbox__close {
  position: absolute;
  top: 14px;
  right: 16px;
  width: 42px;
  height: 42px;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(20, 20, 20, 0.72);
  color: #fff;
  font-size: 28px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10052;
  padding: 0;
}

.global-photo-lightbox__counter {
  position: absolute;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  padding: 4px 12px;
  border-radius: 9999px;
  background: rgba(20, 20, 20, 0.72);
  color: #f3f4f6;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  z-index: 10052;
  pointer-events: none;
}

.global-photo-lightbox__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(20, 20, 20, 0.62);
  color: #fff;
  font-size: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10052;
  padding: 0;
}

.global-photo-lightbox__prev {
  left: 12px;
}

.global-photo-lightbox__next {
  right: 12px;
}

.global-photo-lightbox.single-image .global-photo-lightbox__nav {
  display: none;
}

/* 過去記録ピッカーのサムネイル（拡大対応・視認性アップ） */
.saved-bean-candidate-card {
  width: 176px;
}

.saved-bean-thumb-zoom {
  position: relative;
  width: 56px;
  height: 56px;
  border-radius: 8px;
  overflow: hidden;
  flex-shrink: 0;
  border: 1px solid rgba(168, 155, 145, 0.35);
  cursor: zoom-in;
  padding: 0;
  background: transparent;
}

.saved-bean-thumb-zoom img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.saved-bean-thumb-zoom__badge {
  position: absolute;
  right: 3px;
  bottom: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.68);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.saved-bean-thumb-placeholder {
  width: 56px;
  height: 56px;
  border-radius: 8px;
  background: rgba(201, 138, 75, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}

.modal-photo-preview-item img {
  cursor: zoom-in;
}

.bean-card-zoom-btn {
  position: absolute;
  right: 10px;
  bottom: 10px;
  width: 32px;
  height: 32px;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(20, 16, 14, 0.68);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: zoom-in;
  z-index: 6;
  padding: 0;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.detail-modal-zoom-hint {
  position: absolute;
  right: 12px;
  bottom: 12px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 9999px;
  background: rgba(20, 16, 14, 0.72);
  color: #fff;
  font-size: 11.5px;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.25);
  cursor: zoom-in;
  z-index: 8;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

/* =========================================================
   専用レシピ別タイマーURL向け1行折りたたみガイド・FAQ
   （初期は閉じてタイマー画面のミニマルな操作感を維持）
   ========================================================= */
.recipe-seo-guide {
  max-width: 560px;
  margin: 12px auto 0;
  padding: 0 14px calc(var(--bottom-panel-height) + 120px);
  text-align: left;
  box-sizing: border-box;
}

.recipe-seo-accordion {
  width: 100%;
}

.recipe-seo-accordion__toggle {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 13px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #9ca3af;
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.recipe-seo-accordion__toggle::-webkit-details-marker {
  display: none;
}

.recipe-seo-accordion__toggle:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.18);
  color: #e5e7eb;
}

.recipe-seo-accordion__toggle-text {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
}

.recipe-seo-accordion__toggle-text svg {
  flex-shrink: 0;
  opacity: 0.8;
}

.recipe-seo-accordion__chevron {
  font-size: 12px;
  color: #9ca3af;
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

.recipe-seo-accordion[open] > .recipe-seo-accordion__toggle {
  color: #e5e7eb;
  border-color: rgba(201, 138, 75, 0.35);
  background: rgba(201, 138, 75, 0.08);
}

.recipe-seo-accordion[open] > .recipe-seo-accordion__toggle .recipe-seo-accordion__chevron {
  transform: rotate(180deg);
  color: #f5b971;
}

.recipe-seo-guide__card {
  margin-top: 8px;
  background: #141414;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 14px;
  padding: 16px;
  color: #e5e7eb;
}

.recipe-seo-guide__badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  color: #f5b971;
  background: rgba(201, 138, 75, 0.14);
  border: 1px solid rgba(201, 138, 75, 0.3);
  border-radius: 999px;
  padding: 3px 10px;
  margin-bottom: 8px;
}

.recipe-seo-guide__title {
  margin: 0 0 8px;
  font-size: 16px;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.35;
}

.recipe-seo-guide__lead {
  margin: 0 0 12px;
  font-size: 13px;
  line-height: 1.6;
  color: #cbd5e1;
}

.recipe-seo-guide__specs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

.recipe-seo-guide__spec {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 8px;
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.recipe-seo-guide__spec-label {
  font-size: 11px;
  color: #9ca3af;
}

.recipe-seo-guide__spec-value {
  font-size: 13px;
  color: #f8fafc;
}

.recipe-seo-guide__tips {
  margin: 0 0 14px;
  padding-left: 18px;
  font-size: 12.5px;
  line-height: 1.55;
  color: #d1d5db;
}

.recipe-seo-guide__tips li + li {
  margin-top: 5px;
}

.recipe-seo-guide__subhead {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 700;
  color: #f3f4f6;
}

.recipe-seo-guide__faqs {
  margin-bottom: 14px;
}

.recipe-seo-guide__faq-item {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 8px 0;
}

.recipe-seo-guide__faq-item:last-of-type {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.recipe-seo-guide__faq-item summary {
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  color: #f3f4f6;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.recipe-seo-guide__faq-item summary::-webkit-details-marker {
  display: none;
}

.recipe-seo-guide__faq-item summary::after {
  content: "+";
  color: #9ca3af;
  font-size: 15px;
  flex-shrink: 0;
}

.recipe-seo-guide__faq-item[open] summary::after {
  content: "−";
  color: #f5b971;
}

.recipe-seo-guide__faq-item p {
  margin: 6px 0 2px;
  font-size: 12.5px;
  line-height: 1.6;
  color: #cbd5e1;
}

.recipe-seo-guide__links {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.recipe-seo-guide__links-label {
  font-size: 11.5px;
  color: #9ca3af;
  font-weight: 600;
}

.recipe-seo-guide__pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.recipe-seo-guide__pill {
  display: inline-flex;
  align-items: center;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #e5e7eb;
  font-size: 12px;
  text-decoration: none;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.recipe-seo-guide__pill:hover {
  background: rgba(201, 138, 75, 0.18);
  border-color: rgba(201, 138, 75, 0.45);
  color: #ffffff;
}

.recipe-seo-guide__pill.is-current {
  background: rgba(140, 103, 61, 0.32);
  border-color: #c98a4b;
  color: #fde68a;
  font-weight: 600;
}

