/* うららん 通知設定
 * iOSスタイルのトグル（緑=ON / グレー=OFF）。
 */

:root {
  --c-bg: #F8F8F8;
  --c-surface: #FFFFFF;
  --c-border: #ECECEC;
  --c-text: #2C2C2A;
  --c-text-muted: #7A7770;
  --c-text-hint: #9A968C;
  --c-purple: #7B5BC4;
  --c-toggle-on: #34C759;
  --c-toggle-off: #E5E5EA;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  overflow: hidden;
  background: var(--c-bg);
  color: var(--c-text);
  font-family: system-ui, -apple-system, "Hiragino Kaku Gothic ProN", "Hiragino Sans", "BIZ UDPGothic", sans-serif;
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.app {
  height: 100dvh;
  max-width: 430px;
  margin: 0 auto;
  background: var(--c-surface);
  display: flex;
  flex-direction: column;
}

/* ===== ヘッダー ===== */
.app-header {
  flex: 0 0 auto;
  background: var(--c-surface);
  border-bottom: 0.5px solid var(--c-border);
}
.topbar {
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 52px;
  position: relative;
}
.topbar-back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: 0;
  background: transparent;
  color: var(--c-text);
  cursor: pointer;
  padding: 0;
  flex: 0 0 auto;
}
.topbar-title {
  margin: 0;
  font-size: 17px;
  font-weight: 600;
  color: var(--c-text);
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

/* ===== 本文 ===== */
.notifications-main {
  flex: 1 1 auto;
  overflow-y: auto;
  padding-bottom: calc(84px + env(safe-area-inset-bottom));
  scrollbar-width: none;
}
.notifications-main::-webkit-scrollbar { display: none; }

/* ----- Section title（home.cssと同じスタイル） ----- */
.section-title {
  font-size: 17px;
  font-weight: 500;
  padding: 16px 16px 8px;
  margin: 0;
}

.settings-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.setting-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 16px;
  border-bottom: 0.5px solid var(--c-border);
  background: var(--c-surface);
}
.setting-label {
  font-size: 15px;
  color: var(--c-text);
}

/* ===== iOSスタイル トグル ===== */
.toggle {
  position: relative;
  display: inline-block;
  width: 52px;
  height: 32px;
  flex: 0 0 auto;
}
.toggle input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}
.toggle-track {
  position: absolute;
  inset: 0;
  background: var(--c-toggle-off);
  border-radius: 16px;
  transition: background 0.2s;
  cursor: pointer;
}
.toggle-thumb {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 28px;
  height: 28px;
  background: #fff;
  border-radius: 50%;
  transition: transform 0.2s;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}
.toggle input:checked + .toggle-track {
  background: var(--c-toggle-on);
}
.toggle input:checked + .toggle-track .toggle-thumb {
  transform: translateX(20px);
}

/* ===== Bottom tab bar ===== */
.tabbar {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 430px;
  background: var(--c-surface);
  border-top: 0.5px solid var(--c-border);
  display: flex;
  padding: 8px 0 calc(8px + env(safe-area-inset-bottom));
  z-index: 20;
}
.tab {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  font-size: 10px;
  color: var(--c-text-hint);
  background: transparent;
  border: 0;
  padding: 4px 0;
  font-family: inherit;
  cursor: pointer;
  text-decoration: none;
}
.tab svg { width: 22px; height: 22px; }
.tab.is-active { color: var(--c-purple); }
