/* ベース */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --color-primary: #e07b54;
  --color-primary-light: #f5e6de;
  --color-bg: #fffaf7;
  --color-surface: #ffffff;
  --color-text: #3d2b1f;
  --color-text-muted: #9e7f6e;
  --color-border: #e8d5c8;
  --tab-height: 64px;
  --header-height: 56px;
}

html, body {
  height: 100%;
  font-family: 'Hiragino Sans', 'Hiragino Kaku Gothic ProN', Meiryo, sans-serif;
  background: var(--color-bg);
  color: var(--color-text);
  font-size: 16px;
}

/* ヘッダー */
.app-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  padding: 0 16px;
  z-index: 100;
}

.app-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--color-primary);
  letter-spacing: 0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* メインエリア */
.app-main {
  position: fixed;
  top: var(--header-height);
  left: 0;
  right: 0;
  bottom: calc(var(--tab-height) + env(safe-area-inset-bottom));
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

/* 画面切り替え */
.screen {
  display: none;
  min-height: 100%;
}

.screen.active {
  display: block;
}

.screen-inner {
  padding: 20px 16px;
}

/* プレースホルダーテキスト */
.placeholder-text {
  text-align: center;
  color: var(--color-text-muted);
  font-size: 15px;
  line-height: 1.8;
  margin-top: 48px;
}

/* タブバー */
.tab-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: calc(var(--tab-height) + env(safe-area-inset-bottom));
  padding-bottom: env(safe-area-inset-bottom);
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  display: flex;
  z-index: 100;
}

.tab-btn {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px 0;
  color: var(--color-text-muted);
  transition: color 0.15s;
  -webkit-tap-highlight-color: transparent;
}

.tab-btn.active {
  color: var(--color-primary);
}

.tab-icon {
  font-size: 22px;
  line-height: 1;
}

.tab-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.03em;
}

/* セクションタイトル */
.section-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: 20px;
}

/* フォーム */
.form-group {
  margin-bottom: 18px;
}

.form-label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 6px;
}

.required {
  font-size: 11px;
  color: var(--color-primary);
  font-weight: 700;
  margin-left: 4px;
}

.form-input {
  width: 100%;
  padding: 12px 14px;
  font-size: 16px;
  font-family: inherit;
  color: var(--color-text);
  background: var(--color-surface);
  border: 1.5px solid var(--color-border);
  border-radius: 10px;
  appearance: none;
  -webkit-appearance: none;
  outline: none;
  transition: border-color 0.15s;
}

.form-input:focus {
  border-color: var(--color-primary);
}

.form-select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%239e7f6e' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
  cursor: pointer;
}

.form-textarea {
  min-height: 90px;
  resize: vertical;
  line-height: 1.6;
}

.form-hint {
  font-size: 12px;
  color: var(--color-text-muted);
  margin-top: 4px;
}

.form-group-check {
  margin-bottom: 24px;
}

.check-label {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
}

.check-label input[type="checkbox"] {
  width: 22px;
  height: 22px;
  accent-color: var(--color-primary);
  cursor: pointer;
  flex-shrink: 0;
}

.check-text {
  font-size: 15px;
  color: var(--color-text);
}

.btn-primary {
  display: block;
  width: 100%;
  padding: 16px;
  font-size: 17px;
  font-weight: 700;
  font-family: inherit;
  color: #fff;
  background: var(--color-primary);
  border: none;
  border-radius: 12px;
  cursor: pointer;
  letter-spacing: 0.05em;
  -webkit-tap-highlight-color: transparent;
}

/* レシピカード */
.recipe-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 12px;
}

.card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}

.card-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--color-text);
  line-height: 1.4;
}

.card-fav {
  font-size: 18px;
  flex-shrink: 0;
}

.card-category {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  color: var(--color-primary);
  background: var(--color-primary-light);
  border-radius: 6px;
  padding: 2px 8px;
  margin-right: 6px;
  margin-bottom: 6px;
}

.card-site {
  font-size: 13px;
  color: var(--color-text-muted);
}

.card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 8px;
}

.tag {
  font-size: 12px;
  color: var(--color-text-muted);
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: 6px;
  padding: 2px 8px;
}

.card-memo {
  font-size: 13px;
  color: var(--color-text-muted);
  line-height: 1.6;
  margin-top: 8px;
}

.card-link {
  display: inline-block;
  margin-top: 10px;
  font-size: 14px;
  font-weight: 600;
  color: var(--color-primary);
  text-decoration: none;
}

/* カードアクションボタン */
.card-actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--color-border);
}

.btn-edit,
.btn-delete {
  flex: 1;
  padding: 10px 0;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.btn-edit {
  color: var(--color-primary);
  background: var(--color-primary-light);
}

.btn-delete {
  color: #c0392b;
  background: #fdecea;
}

/* 編集バナー */
.edit-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #fff8e1;
  border: 1px solid #ffe082;
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 600;
  color: #7c5c00;
  margin-bottom: 16px;
}

.btn-cancel {
  padding: 6px 16px;
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  color: #7c5c00;
  background: #fff;
  border: 1px solid #ffe082;
  border-radius: 8px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

/* レシピ種別トグル */
.type-toggle {
  display: flex;
  gap: 8px;
}

.type-option {
  flex: 1;
  cursor: pointer;
}

.type-option input[type="radio"] {
  display: none;
}

.type-option span {
  display: block;
  text-align: center;
  padding: 10px 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text-muted);
  background: var(--color-bg);
  border: 1.5px solid var(--color-border);
  border-radius: 10px;
  transition: all 0.15s;
}

.type-option input[type="radio"]:checked + span {
  color: var(--color-primary);
  background: var(--color-primary-light);
  border-color: var(--color-primary);
}

/* 自分レシピバッジ */
.card-my-badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  color: #5c7a3e;
  background: #eaf4e0;
  border-radius: 6px;
  padding: 2px 8px;
  margin-right: 6px;
  margin-bottom: 6px;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 2px;
}

/* 材料・作り方 */
.card-section {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--color-border);
}

.card-section-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--color-text-muted);
  margin-bottom: 4px;
}

.card-section-body {
  font-size: 15px;
  color: var(--color-text);
  line-height: 1.7;
  white-space: pre-line;
}

.form-textarea-lg {
  min-height: 130px;
}

/* 材料入力行 */
#materials-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 8px;
}

.material-row {
  display: flex;
  gap: 6px;
  align-items: center;
}

.material-name {
  flex: 2;
}

.material-amount {
  flex: 1;
}

.btn-del-material {
  flex-shrink: 0;
  width: 36px;
  height: 44px;
  font-size: 14px;
  color: #c0392b;
  background: #fdecea;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.btn-add-material {
  display: block;
  width: 100%;
  padding: 10px;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  color: var(--color-primary);
  background: var(--color-primary-light);
  border: 1.5px dashed var(--color-primary);
  border-radius: 10px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

/* カード内の材料リスト */
.card-materials {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 4px;
}

.material-item {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  font-size: 14px;
  line-height: 1.8;
  border-bottom: 1px dotted var(--color-border);
  padding: 2px 0;
}

.material-item:last-child {
  border-bottom: none;
}

.material-item-name {
  flex: 1;
  color: var(--color-text);
  min-width: 0;
}

.material-item-amount {
  flex-shrink: 0;
  color: var(--color-text-muted);
  text-align: right;
  white-space: nowrap;
}

/* 手順入力行 */
#steps-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 8px;
}

.step-row {
  display: flex;
  gap: 6px;
  align-items: flex-start;
}

.step-num {
  flex-shrink: 0;
  width: 24px;
  padding-top: 11px;
  font-size: 14px;
  font-weight: 700;
  color: var(--color-primary);
  text-align: right;
}

.step-text {
  flex: 1;
  min-height: 56px;
  resize: vertical;
  line-height: 1.5;
}

.btn-del-step {
  flex-shrink: 0;
  width: 36px;
  height: 44px;
  font-size: 14px;
  color: #c0392b;
  background: #fdecea;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.btn-add-step {
  display: block;
  width: 100%;
  padding: 10px;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  color: var(--color-primary);
  background: var(--color-primary-light);
  border: 1.5px dashed var(--color-primary);
  border-radius: 10px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

/* カード内の手順リスト */
.card-steps {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 4px;
}

.step-item {
  display: flex;
  gap: 6px;
  font-size: 15px;
  line-height: 1.6;
}

.step-item-num {
  flex-shrink: 0;
  font-weight: 700;
  color: var(--color-primary);
}

.step-item-text {
  color: var(--color-text);
}

/* 検索欄 */
.search-box {
  margin-bottom: 10px;
}

.search-input {
  width: 100%;
  padding: 11px 14px;
  font-size: 16px;
  font-family: inherit;
  color: var(--color-text);
  background: var(--color-surface);
  border: 1.5px solid var(--color-border);
  border-radius: 10px;
  outline: none;
  -webkit-appearance: none;
}

.search-input:focus {
  border-color: var(--color-primary);
}

/* 絞り込みバー */
.filter-bar {
  margin-bottom: 6px;
}

.btn-filter-toggle {
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  color: var(--color-text-muted);
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: 20px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.btn-filter-toggle.btn-filter-active {
  color: var(--color-primary);
  background: var(--color-primary-light);
  border-color: var(--color-primary);
}

/* 絞り込みパネル */
.filter-panel {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 12px;
  margin-bottom: 10px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

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

.filter-row-label {
  flex-shrink: 0;
  font-size: 12px;
  font-weight: 600;
  color: var(--color-text-muted);
  width: 46px;
}

.filter-chips-scroll {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 2px;
  flex: 1;
}

.filter-chips-scroll::-webkit-scrollbar {
  display: none;
}

.filter-chip {
  flex-shrink: 0;
  padding: 5px 12px;
  font-size: 13px;
  font-weight: 500;
  font-family: inherit;
  color: var(--color-text-muted);
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: 20px;
  cursor: pointer;
  white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
}

.filter-chip.active {
  color: var(--color-primary);
  background: var(--color-primary-light);
  border-color: var(--color-primary);
}

.filter-fav-btn {
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  color: var(--color-text-muted);
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: 20px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.filter-fav-btn.active {
  color: #c47a00;
  background: #fff8e1;
  border-color: #ffe082;
}

/* 一覧ヘッダー */
.list-header {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-bottom: 8px;
}

.btn-select-delete {
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  color: var(--color-text-muted);
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.btn-confirm-delete {
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  color: #c0392b;
  background: #fdecea;
  border: 1px solid #f5c6c6;
  border-radius: 8px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.btn-cancel-select {
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  color: var(--color-text-muted);
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

/* 一覧アイテム */
.list-item {
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--color-border);
}

.list-item:last-child {
  border-bottom: none;
}

.list-checkbox {
  width: 22px;
  height: 22px;
  accent-color: var(--color-primary);
  flex-shrink: 0;
  cursor: pointer;
  margin-right: 4px;
}

.list-item-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 2px;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  min-width: 0;
  -webkit-tap-highlight-color: transparent;
}

.list-item-inner {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
}

.list-item-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.list-badge-my {
  flex-shrink: 0;
  font-size: 11px;
  font-weight: 700;
  color: #5c7a3e;
  background: #eaf4e0;
  border-radius: 4px;
  padding: 1px 5px;
}

.list-item-right {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
  margin-left: 8px;
}

.list-item-fav {
  font-size: 15px;
}

.list-item-arrow {
  font-size: 20px;
  color: var(--color-border);
  line-height: 1;
}

.list-item-ext {
  font-size: 14px;
  color: var(--color-text-muted);
}

.list-item-more {
  flex-shrink: 0;
  width: 40px;
  height: 48px;
  background: none;
  border: none;
  font-size: 18px;
  color: var(--color-text-muted);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.list-item-text {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 2px;
  min-width: 0;
}

/* 詳細画面 */
.btn-back {
  display: inline-flex;
  align-items: center;
  padding: 12px 0;
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  color: var(--color-primary);
  background: none;
  border: none;
  cursor: pointer;
  margin-bottom: 8px;
  -webkit-tap-highlight-color: transparent;
  min-height: 44px;
}

.detail-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}

.detail-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--color-text);
  line-height: 1.4;
}

.detail-fav {
  font-size: 20px;
  flex-shrink: 0;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  margin-bottom: 8px;
}

.detail-url-badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  color: #2c6e9e;
  background: #deedf7;
  border-radius: 6px;
  padding: 2px 8px;
}

.detail-memo {
  font-size: 14px;
  color: var(--color-text-muted);
  line-height: 1.6;
  margin: 10px 0;
  padding: 10px 12px;
  background: var(--color-bg);
  border-radius: 8px;
}

.btn-open-recipe {
  display: block;
  padding: 14px;
  font-size: 16px;
  font-weight: 700;
  font-family: inherit;
  color: #fff;
  background: var(--color-primary);
  border: none;
  border-radius: 12px;
  text-align: center;
  text-decoration: none;
  margin: 16px 0;
}

.detail-url-link {
  display: block;
  font-size: 13px;
  color: var(--color-primary);
  word-break: break-all;
  line-height: 1.6;
  margin: 8px 0;
}

.detail-actions {
  display: flex;
  gap: 8px;
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid var(--color-border);
}

.btn-edit-detail,
.btn-delete-detail {
  flex: 1;
  padding: 12px 0;
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.btn-edit-detail {
  color: var(--color-primary);
  background: var(--color-primary-light);
}

.btn-delete-detail {
  color: #c0392b;
  background: #fdecea;
}

/* 詳細画面：今日作るに追加ボタン */
.btn-add-today {
  display: block;
  width: 100%;
  padding: 14px;
  font-size: 16px;
  font-weight: 700;
  font-family: inherit;
  color: #fff;
  background: #5c9e5c;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  text-align: center;
  margin: 16px 0 4px;
  -webkit-tap-highlight-color: transparent;
}

.btn-add-today.btn-add-today-added {
  color: #5c7a3e;
  background: #eaf4e0;
  cursor: default;
}

/* 今日作るリスト */
.today-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.btn-today-clear {
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  color: #c0392b;
  background: #fdecea;
  border: 1px solid #f5c6c6;
  border-radius: 8px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.today-item {
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--color-border);
}

.today-item:last-child {
  border-bottom: none;
}

.today-item-btn {
  flex: 1;
  display: flex;
  align-items: center;
  padding: 14px 2px;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  min-width: 0;
  -webkit-tap-highlight-color: transparent;
  text-decoration: none;
}

.today-item-inner {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
}

.today-item-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
}

.today-item-ext {
  font-size: 14px;
  color: var(--color-text-muted);
  flex-shrink: 0;
}

.today-item-arrow {
  font-size: 20px;
  color: var(--color-border);
  line-height: 1;
  flex-shrink: 0;
}

.today-item-delete {
  flex-shrink: 0;
  width: 40px;
  height: 48px;
  background: none;
  border: none;
  font-size: 16px;
  color: var(--color-text-muted);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

/* 今日アイテム：同時調理トグルボタン */
.today-item-cook {
  flex-shrink: 0;
  width: 40px;
  height: 48px;
  background: none;
  border: none;
  font-size: 15px;
  color: var(--color-text-muted);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.today-item-cook.in-cook {
  color: var(--color-primary);
}

/* 同時調理を開始ボタン */
.btn-cook-start {
  display: block;
  width: 100%;
  padding: 16px;
  font-size: 17px;
  font-weight: 700;
  font-family: inherit;
  color: #fff;
  background: var(--color-primary);
  border: none;
  border-radius: 12px;
  cursor: pointer;
  margin-top: 20px;
  -webkit-tap-highlight-color: transparent;
}

.btn-cook-start:disabled {
  background: var(--color-border);
  color: var(--color-text-muted);
  cursor: default;
}

/* 同時調理画面 */
.cook-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.btn-cook-clear {
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  color: #c0392b;
  background: #fdecea;
  border: 1px solid #f5c6c6;
  border-radius: 8px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.cook-tabs {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 10px;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--color-border);
}

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

.cook-tab {
  flex-shrink: 0;
  padding: 10px 18px;
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  color: var(--color-text-muted);
  background: var(--color-bg);
  border: 1.5px solid var(--color-border);
  border-radius: 20px;
  cursor: pointer;
  white-space: nowrap;
  max-width: 160px;
  overflow: hidden;
  text-overflow: ellipsis;
  -webkit-tap-highlight-color: transparent;
}

.cook-tab.active {
  color: var(--color-primary);
  background: var(--color-primary-light);
  border-color: var(--color-primary);
}

.cook-recipe-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}

.cook-recipe-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--color-text);
  line-height: 1.4;
  flex: 1;
}

.btn-cook-remove {
  flex-shrink: 0;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
  font-family: inherit;
  color: var(--color-text-muted);
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

/* 設定画面 */
.settings-section {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 20px 16px;
}

.settings-section-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: 10px;
}

.settings-desc {
  font-size: 14px;
  color: var(--color-text-muted);
  line-height: 1.6;
  margin-bottom: 16px;
}

.settings-divider {
  border-top: 1px solid var(--color-border);
  margin: 20px 0;
}

.btn-backup-export {
  display: block;
  width: 100%;
  padding: 16px;
  font-size: 16px;
  font-weight: 700;
  font-family: inherit;
  color: #fff;
  background: var(--color-primary);
  border: none;
  border-radius: 12px;
  cursor: pointer;
  text-align: center;
  -webkit-tap-highlight-color: transparent;
}

.btn-backup-import {
  display: block;
  width: 100%;
  padding: 16px;
  font-size: 16px;
  font-weight: 700;
  font-family: inherit;
  color: var(--color-primary);
  background: var(--color-primary-light);
  border: 2px solid var(--color-primary);
  border-radius: 12px;
  cursor: pointer;
  text-align: center;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

.import-error {
  margin-top: 10px;
  padding: 10px 12px;
  font-size: 14px;
  color: #c0392b;
  background: #fdecea;
  border-radius: 8px;
  line-height: 1.5;
}
