:root {
  --primary-color: #4a86e8;
  --secondary-color: #6aa84f;
  --danger-color: #e74c3c;
  --text-color: #333;
  --light-text-color: #777;
  --background-color: #f5f5f5;
  --card-background: #fff;
  --light-gray: #f5f5f5;
  --border-color: #ddd;
  --priority-high: #e74c3c;
  --priority-medium: #f39c12;
  --priority-low: #6aa84f;
  --overdue: #e74c3c;
  --due-today: #f39c12;
  --tag-background: #eee;
  --link-color: #4a86e8;
  --timer-background: #f1f8ff;
  --timer-running: #4caf50;
  --timer-paused: #f39c12;
  --timer-reset: #9e9e9e;
  --chart-bar-color: #4a86e8;
  --chart-bar-hover: #5b95f9;
  --chart-progress-bg: #e8f0fe;
  
  /* ポモドーロテーマ */
  --pomodoro-work: #e57373;
  --pomodoro-work-dark: #c62828;
  --pomodoro-short-break: #81c784;
  --pomodoro-short-break-dark: #388e3c;
  --pomodoro-long-break: #64b5f6;
  --pomodoro-long-break-dark: #1976d2;
  
  /* リマインダーテーマ */
  --reminder-bg: #fef9e6;
  --reminder-border: #f6e9a6;
  --reminder-today: #fff8cc;
  --reminder-badge: #f39c12;
}

/* ダークテーマ */
.dark-theme {
  --primary-color: #5a96f8;
  --secondary-color: #7ab85f;
  --danger-color: #ff5a4f;
  --text-color: #f0f0f0;
  --light-text-color: #aaa;
  --background-color: #242424;
  --card-background: #333;
  --light-gray: #3a3a3a;
  --border-color: #444;
  --priority-high: #ff5a4f;
  --priority-medium: #ffac29;
  --priority-low: #7ab85f;
  --tag-background: #4a4a4a;
  --link-color: #5a96f8;
  --timer-background: #2a3952;
  --timer-running: #4caf50;
  --timer-paused: #f39c12;
  --timer-reset: #9e9e9e;
  --chart-bar-color: #5a96f8;
  --chart-bar-hover: #6ba5ff;
  --chart-progress-bg: #3a4a63;
  
  /* ポモドーロテーマ (ダーク) */
  --pomodoro-work: #ff5252;
  --pomodoro-work-dark: #b71c1c;
  --pomodoro-short-break: #69f0ae;
  --pomodoro-short-break-dark: #00c853;
  --pomodoro-long-break: #40c4ff;
  --pomodoro-long-break-dark: #0091ea;
  
  /* リマインダーテーマ (ダーク) */
  --reminder-bg: #353626;
  --reminder-border: #665e35;
  --reminder-today: #4d4a30;
  --reminder-badge: #f39c12;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.6;
  color: var(--text-color);
  background-color: var(--background-color);
  padding: 20px;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.container {
  width: 95%;
  max-width: 1200px;
  margin: 0 auto;
  background-color: var(--card-background);
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  padding: 20px;
  transition: background-color 0.3s ease;
}

header {
  padding-bottom: 20px;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
}

@media (max-width: 600px) {
  header {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .header-content {
    width: 100%;
    margin-bottom: 15px;
  }
  
  .header-controls {
    width: 100%;
    justify-content: flex-start;
  }
}

h1 {
  color: var(--primary-color);
}

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

.theme-toggle,
.help-toggle,
.analytics-toggle {
  margin-left: 5px;
}

.icon-btn {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  padding: 5px;
}

.import-export {
  display: flex;
  gap: 10px;
  margin-top: 10px;
}

.secondary-btn {
  background-color: var(--light-gray);
  color: var(--text-color);
  border: 1px solid var(--border-color);
}

.new-task-form {
  margin-bottom: 30px;
  background-color: var(--light-gray);
  padding: 20px;
  border-radius: 8px;
}

.form-group {
  margin-bottom: 15px;
}

label {
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
}

input[type="text"],
input[type="date"],
textarea,
select {
  width: 100%;
  padding: 10px;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  font-size: 16px;
  background-color: var(--card-background);
  color: var(--text-color);
}

textarea {
  height: 100px;
  resize: vertical;
}

button {
  background-color: var(--primary-color);
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 16px;
  transition: opacity 0.2s ease;
}

button:hover {
  opacity: 0.9;
}

/* タスク統計 */
.task-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  margin-bottom: 20px;
  padding: 15px;
  background-color: var(--light-gray);
  border-radius: 8px;
}

.stat-item {
  text-align: center;
  flex: 1;
  min-width: 80px;
  padding: 10px;
  border-radius: 4px;
  background-color: var(--card-background);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.stat-value {
  display: block;
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--primary-color);
}

.stat-label {
  font-size: 0.8rem;
  color: var(--light-text-color);
}

.stat-item.overdue .stat-value {
  color: var(--overdue);
}

.stat-item.today .stat-value {
  color: var(--due-today);
}

/* タスクコントロール */
.task-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  margin-bottom: 20px;
  padding: 15px;
  background-color: var(--light-gray);
  border-radius: 8px;
}

.filter-controls,
.sort-controls,
.search-controls {
  flex: 1;
  min-width: 200px;
}

.search-controls input {
  transition: all 0.3s ease;
  border: 1px solid var(--border-color);
}

.search-controls input:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(74, 134, 232, 0.2);
}

/* タスクセクション */
.task-section {
  margin-bottom: 30px;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
  padding-bottom: 5px;
  border-bottom: 1px solid var(--border-color);
}

.task-section h2 {
  color: var(--primary-color);
  margin: 0;
}

.task-item {
  list-style: none;
  padding: 15px;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  margin-bottom: 10px;
  background-color: var(--card-background);
  transition: transform 0.2s ease;
  position: relative;
  overflow: hidden;
}

.task-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.task-item.selected {
  box-shadow: 0 0 0 2px var(--primary-color);
  transform: translateY(-2px);
  transition: box-shadow 0.2s ease;
}

/* ドラッグアンドドロップ関連のスタイル */
.task-item.dragging {
  opacity: 0.5;
  cursor: grabbing;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  transform: scale(0.98);
}

.task-item.drop-target {
  border: 2px dashed var(--primary-color);
  background-color: rgba(74, 134, 232, 0.05);
  transform: translateY(-2px);
}

.pending-tasks ul.drop-target,
.completed-tasks ul.drop-target {
  min-height: 50px;
  border: 2px dashed var(--primary-color);
  background-color: rgba(74, 134, 232, 0.05);
  border-radius: 4px;
  padding: 10px;
}

.drag-handle {
  cursor: grab;
  color: var(--light-text-color);
  padding: 0 8px;
  font-size: 1.2rem;
  line-height: 1;
  user-select: none;
  transition: color 0.2s ease;
  font-weight: bold;
}

.drag-handle:hover {
  color: var(--primary-color);
}

.drag-handle:active {
  cursor: grabbing;
}

.task-item.completed {
  background-color: var(--light-gray);
  opacity: 0.8;
}

.task-item.overdue::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background-color: var(--overdue);
}

.task-item.due-today::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background-color: var(--due-today);
}

.priority-high {
  border-left: 4px solid var(--priority-high);
}

.priority-medium {
  border-left: 4px solid var(--priority-medium);
}

.priority-low {
  border-left: 4px solid var(--priority-low);
}

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

.task-title-area {
  display: flex;
  align-items: center;
  gap: 10px;
}

.priority-marker {
  display: inline-block;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: bold;
  color: white;
}

.priority-marker.high {
  background-color: var(--priority-high);
}

.priority-marker.medium {
  background-color: var(--priority-medium);
}

.priority-marker.low {
  background-color: var(--priority-low);
}

.task-header h3 {
  margin: 0;
  word-break: break-word;
}

.task-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.task-actions button {
  padding: 5px 10px;
  font-size: 0.85rem;
}

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

.complete-btn {
  background-color: var(--secondary-color);
}

.uncomplete-btn {
  background-color: var(--light-gray);
  color: var(--text-color);
  border: 1px solid var(--border-color);
}

.delete-btn {
  background-color: var(--danger-color);
}

.task-description {
  margin-bottom: 10px;
  color: var(--text-color);
  line-height: 1.5;
}

.task-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 10px;
}

.task-tag {
  display: inline-block;
  padding: 2px 8px;
  background-color: var(--tag-background);
  border-radius: 12px;
  font-size: 0.8rem;
}

.task-notes {
  margin-bottom: 10px;
  padding: 10px;
  background-color: var(--light-gray);
  border-radius: 4px;
  font-size: 0.9rem;
}

.task-notes p {
  margin-top: 5px;
}

.task-meta {
  font-size: 0.8em;
  color: var(--light-text-color);
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
}

.due-date {
  font-weight: bold;
}

.due-date.overdue {
  color: var(--overdue);
}

/* モーダル */
.edit-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

/* モーダルのz-indexを確実に最前面に */
.keyboard-help-modal {
  z-index: 1001 !important;
}

.modal-content {
  background-color: var(--card-background);
  padding: 20px;
  border-radius: 8px;
  width: 90%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-content h2 {
  margin-bottom: 20px;
  color: var(--primary-color);
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 20px;
}

.save-btn {
  background-color: var(--secondary-color);
}

.cancel-btn {
  background-color: var(--light-gray);
  color: var(--text-color);
}

/* タイマー */
.timer-container {
  margin-bottom: 20px;
  padding: 15px;
  background-color: var(--timer-background);
  border-radius: 8px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.timer-display {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
  flex-wrap: wrap;
}

.timer-task-info {
  flex: 1;
  min-width: 200px;
}

.timer-label {
  display: block;
  font-size: 0.85rem;
  color: var(--light-text-color);
  margin-bottom: 5px;
}

#timer-task-title {
  font-weight: bold;
  word-break: break-word;
}

.timer-time {
  font-size: 2rem;
  font-weight: bold;
  font-family: monospace;
  padding: 10px;
  border-radius: 4px;
  background-color: var(--card-background);
  min-width: 150px;
  text-align: center;
}

.timer-controls {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 10px;
}

.timer-btn {
  padding: 8px 15px;
  font-size: 0.9rem;
  border-radius: 4px;
  flex: 1;
  max-width: 120px;
}

.timer-btn.start {
  background-color: var(--timer-running);
}

.timer-btn.pause {
  background-color: var(--timer-paused);
}

.timer-btn.reset {
  background-color: var(--timer-reset);
}

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

.timer-reports {
  text-align: right;
  margin-top: 10px;
}

/* タイマーレポート */
.timer-report-summary {
  margin-bottom: 20px;
  padding: 15px;
  background-color: var(--light-gray);
  border-radius: 8px;
}

.timer-report-details h3 {
  margin-bottom: 15px;
  color: var(--primary-color);
}

.timer-report-list {
  list-style: none;
  padding: 0;
}

.timer-report-item {
  margin-bottom: 15px;
  padding: 10px;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  background-color: var(--card-background);
}

.timer-report-task {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 10px;
}

.timer-report-title {
  font-weight: bold;
}

.timer-report-time {
  font-family: monospace;
  font-weight: bold;
}

.session-list {
  list-style: none;
  padding: 0;
  margin-top: 10px;
}

.session-item {
  display: flex;
  justify-content: space-between;
  padding: 5px 0;
  border-bottom: 1px dashed var(--border-color);
  font-size: 0.9rem;
}

.session-time {
  color: var(--light-text-color);
}

.session-duration {
  font-family: monospace;
}

details summary {
  cursor: pointer;
  padding: 5px 0;
  color: var(--primary-color);
}

/* タスクアイテムのタイマーボタン */
.task-timer-btn {
  background-color: var(--timer-background);
  color: var(--text-color);
  border: 1px solid var(--border-color);
  padding: 3px 6px;
  font-size: 0.75rem;
}

.task-timer-btn.running {
  background-color: var(--timer-running);
  color: white;
}

/* フッター */
footer {
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid var(--border-color);
  text-align: center;
  color: var(--light-text-color);
  font-size: 0.9rem;
}

footer a {
  color: var(--link-color);
  text-decoration: none;
}

footer a:hover {
  text-decoration: underline;
}

.required {
  color: var(--danger-color);
}

/* アナリティクスダッシュボード */
.analytics-dashboard {
  margin-top: 20px;
}

.dashboard-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.dashboard-header h2 {
  margin: 0;
}

.dashboard-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 20px;
}

.dashboard-detail-row, 
.dashboard-row {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 20px;
}

.dashboard-card {
  flex: 1;
  min-width: 250px;
  background-color: var(--card-background);
  border-radius: 8px;
  padding: 15px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.dashboard-card.wide {
  flex: 2;
  min-width: 500px;
}

.dashboard-card h3 {
  margin-top: 0;
  margin-bottom: 15px;
  color: var(--primary-color);
  font-size: 1.1rem;
}

.card-content {
  min-height: 100px;
}

/* 完了率表示 */
.completion-rate-display {
  text-align: center;
  padding: 10px 0;
}

.rate-value {
  font-size: 2.5rem;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 10px;
}

.progress-bar {
  height: 12px;
  background-color: var(--chart-progress-bg);
  border-radius: 6px;
  overflow: hidden;
  margin: 0 auto;
  max-width: 200px;
}

.progress {
  height: 100%;
  background-color: var(--primary-color);
  border-radius: 6px;
}

/* 優先度分布 */
.distribution-bar {
  height: 20px;
  display: flex;
  border-radius: 6px;
  overflow: hidden;
  margin-bottom: 15px;
}

.priority-high, 
.priority-medium, 
.priority-low {
  height: 100%;
}

.distribution-bar .priority-high {
  background-color: var(--priority-high);
}

.distribution-bar .priority-medium {
  background-color: var(--priority-medium);
}

.distribution-bar .priority-low {
  background-color: var(--priority-low);
}

.distribution-legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-around;
}

.legend-item {
  display: flex;
  align-items: center;
  margin-right: 10px;
  font-size: 0.9rem;
}

.legend-color {
  display: inline-block;
  width: 12px;
  height: 12px;
  margin-right: 5px;
  border-radius: 2px;
}

.legend-color.high {
  background-color: var(--priority-high);
}

.legend-color.medium {
  background-color: var(--priority-medium);
}

.legend-color.low {
  background-color: var(--priority-low);
}

/* 期限日分析 */
.due-date-stats {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.stat-group {
  display: flex;
  justify-content: space-around;
}

.stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.stat-label {
  font-size: 0.9rem;
  color: var(--light-text-color);
}

.stat-value {
  font-size: 1.5rem;
  font-weight: bold;
}

.stats-details {
  display: flex;
  justify-content: space-around;
  font-size: 0.9rem;
}

.stats-details h4 {
  margin-top: 0;
  margin-bottom: 5px;
  font-size: 1rem;
}

.stats-details ul {
  list-style: none;
  padding-left: 0;
}

/* トレンドチャート */
.trend-controls {
  display: flex;
  gap: 10px;
  margin-bottom: 15px;
}

.period-btn {
  background-color: var(--light-gray);
  color: var(--text-color);
  border: 1px solid var(--border-color);
  padding: 5px 10px;
  font-size: 0.85rem;
  border-radius: 4px;
  cursor: pointer;
}

.period-btn.active {
  background-color: var(--primary-color);
  color: white;
}

.trend-chart {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  height: 200px;
}

.chart-column {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  min-width: 30px;
}

.chart-bar-container {
  height: 150px;
  display: flex;
  align-items: flex-end;
  width: 100%;
  margin-bottom: 10px;
}

.chart-bar {
  width: 75%;
  max-width: 30px;
  background-color: var(--chart-bar-color);
  border-radius: 4px 4px 0 0;
  transition: all 0.2s ease;
}

.chart-bar:hover {
  background-color: var(--chart-bar-hover);
}

.chart-label {
  font-size: 0.8rem;
  margin-bottom: 5px;
  color: var(--light-text-color);
}

.chart-value {
  font-size: 0.9rem;
  font-weight: bold;
}

/* 曜日別チャート */
.day-of-week-chart {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  height: 150px;
}

.dow-column {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
}

.dow-bar-container {
  height: 120px;
  display: flex;
  align-items: flex-end;
  width: 100%;
  margin-bottom: 10px;
}

.dow-bar {
  width: 75%;
  max-width: 24px;
  background-color: var(--chart-bar-color);
  border-radius: 4px 4px 0 0;
  transition: all 0.2s ease;
}

.dow-bar:hover {
  background-color: var(--chart-bar-hover);
}

.dow-label {
  font-size: 0.8rem;
  color: var(--light-text-color);
}

/* タグ分布 */
.tags-distribution {
  display: flex;
  flex-direction: column;
  gap: 15px;
  max-height: 300px;
  overflow-y: auto;
}

.tag-item {
  padding: 10px;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  background-color: var(--light-gray);
}

.tag-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 5px;
}

.tag-name {
  font-weight: bold;
}

.tag-count {
  font-size: 0.9rem;
  color: var(--light-text-color);
}

.tag-progress-bar {
  height: 8px;
  background-color: var(--chart-progress-bg);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 5px;
}

.tag-progress {
  height: 100%;
  background-color: var(--secondary-color);
}

.tag-completion-rate {
  font-size: 0.8rem;
  color: var(--light-text-color);
}

/* 作業時間分析 */
.work-time-analysis {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.work-time-summary {
  display: flex;
  justify-content: space-around;
  margin-bottom: 10px;
}

.work-time-detail {
  display: flex;
  gap: 20px;
  font-size: 0.9rem;
}

.work-time-by-priority,
.work-time-by-status {
  flex: 1;
}

.work-time-by-priority h4,
.work-time-by-status h4 {
  margin-top: 0;
  margin-bottom: 10px;
  font-size: 1rem;
}

.work-time-by-priority ul,
.work-time-by-status ul {
  list-style: none;
  padding-left: 0;
}

.work-time-by-priority li,
.work-time-by-status li {
  display: flex;
  align-items: center;
  margin-bottom: 5px;
}

/* 生産性メトリクス */
.productivity-metrics {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.metric {
  text-align: center;
  margin-bottom: 15px;
}

.metric-value {
  font-size: 2.5rem;
  font-weight: bold;
  color: var(--primary-color);
  display: block;
}

.metric-label {
  font-size: 0.9rem;
  color: var(--light-text-color);
}

.metric-details {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin-bottom: 15px;
}

.detail-item {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
}

.productivity-tip {
  font-size: 0.9rem;
  text-align: center;
  color: var(--light-text-color);
}

/* 最も生産的な日 */
.most-productive-day {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px;
}

.productive-day-value {
  text-align: center;
  margin-bottom: 15px;
}

.day-name {
  font-size: 1.8rem;
  font-weight: bold;
  color: var(--primary-color);
  display: block;
}

.day-time {
  font-family: monospace;
  font-size: 1.2rem;
}

.productive-day-details {
  font-size: 0.9rem;
  color: var(--light-text-color);
  text-align: center;
}

/* ポモドーロウィジェット */
.pomodoro-widget {
  border-radius: 8px;
  padding: 15px;
  margin-bottom: 20px;
  background-color: var(--card-background);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  position: fixed;
  top: 20px;
  right: 20px;
  width: 280px;
  z-index: 100;
  border: 1px solid var(--border-color);
}

/* モード別スタイル */
.pomodoro-widget.work-mode {
  border-left: 5px solid var(--pomodoro-work);
}

.pomodoro-widget.short-break-mode {
  border-left: 5px solid var(--pomodoro-short-break);
}

.pomodoro-widget.long-break-mode {
  border-left: 5px solid var(--pomodoro-long-break);
}

/* ウィジェットとして表示されるときの追加スタイル */
.pomodoro-widget.widget-mode {
  padding: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

.pomodoro-widget.widget-mode .pomodoro-header h3 {
  font-size: 0.95rem;
}

.pomodoro-widget.widget-mode .pomodoro-timer {
  font-size: 2.5rem;
}

.pomodoro-widget.widget-mode .pomodoro-mode,
.pomodoro-widget.widget-mode .pomodoro-cycle {
  font-size: 0.85rem;
}

.pomodoro-widget.widget-mode .pomodoro-controls {
  margin-bottom: 10px;
}

.pomodoro-widget.widget-mode .pomodoro-stats {
  font-size: 0.8rem;
}

/* 折りたたみ機能 */
.pomodoro-widget.collapsed {
  width: auto;
  padding: 10px;
  max-width: 140px;
}

.pomodoro-widget.collapsed .pomodoro-display {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  margin-bottom: 0;
}

.pomodoro-widget.collapsed .pomodoro-timer {
  font-size: 1.2rem;
  margin-right: 5px;
}

.pomodoro-widget.collapsed .pomodoro-mode,
.pomodoro-widget.collapsed .pomodoro-cycle,
.pomodoro-widget.collapsed .pomodoro-progress,
.pomodoro-widget.collapsed .pomodoro-controls,
.pomodoro-widget.collapsed .pomodoro-stats {
  display: none;
}

.pomodoro-widget.collapsed .pomodoro-header {
  margin-bottom: 5px;
}

/* ホバー時に半透明にする */
.pomodoro-widget.widget-mode:not(:hover) {
  opacity: 0.85;
  transition: opacity 0.3s ease;
}

.pomodoro-widget.widget-mode:hover {
  opacity: 1;
}

.pomodoro-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
}

.pomodoro-header h3 {
  margin: 0;
  color: var(--text-color);
  display: flex;
  align-items: center;
  gap: 10px;
}

.widget-controls {
  display: flex;
  align-items: center;
  gap: 5px;
}

.pomodoro-toggle-btn,
.pomodoro-settings-btn {
  background: none;
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
  padding: 5px;
  transition: all 0.2s ease;
}

.pomodoro-toggle-btn:hover,
.pomodoro-settings-btn:hover {
  background-color: rgba(0, 0, 0, 0.05);
  border-radius: 50%;
}

.pomodoro-display {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 15px;
}

.pomodoro-timer {
  font-size: 3rem;
  font-weight: bold;
  font-family: monospace;
}

.work-mode .pomodoro-timer {
  color: var(--pomodoro-work-dark);
}

.short-break-mode .pomodoro-timer {
  color: var(--pomodoro-short-break-dark);
}

.long-break-mode .pomodoro-timer {
  color: var(--pomodoro-long-break-dark);
}

.pomodoro-mode {
  font-size: 1.2rem;
  margin: 5px 0;
}

.pomodoro-cycle {
  font-size: 0.9rem;
  color: var(--light-text-color);
}

.pomodoro-progress {
  margin-bottom: 15px;
}

.work-mode .progress {
  background-color: var(--pomodoro-work);
}

.short-break-mode .progress {
  background-color: var(--pomodoro-short-break);
}

.long-break-mode .progress {
  background-color: var(--pomodoro-long-break);
}

.pomodoro-controls {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 15px;
}

.pomodoro-start-btn,
.pomodoro-pause-btn,
.pomodoro-reset-btn,
.pomodoro-skip-btn {
  padding: 8px 15px;
  border-radius: 4px;
  border: none;
  cursor: pointer;
  font-size: 0.9rem;
}

.pomodoro-start-btn {
  background-color: var(--timer-running);
  color: white;
}

.pomodoro-pause-btn {
  background-color: var(--timer-paused);
  color: white;
}

.pomodoro-reset-btn,
.pomodoro-skip-btn {
  background-color: var(--light-gray);
  color: var(--text-color);
  border: 1px solid var(--border-color);
}

.pomodoro-controls button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.pomodoro-stats {
  text-align: center;
  font-size: 0.9rem;
  color: var(--light-text-color);
}

/* ポモドーロ統計 */
.pomodoro-stats-summary {
  margin-top: 20px;
  padding-top: 15px;
  border-top: 1px solid var(--border-color);
}

.stats-summary {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 20px;
}

.stats-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.stats-item {
  flex: 1;
  min-width: 120px;
  background-color: var(--light-gray);
  padding: 10px;
  border-radius: 4px;
  text-align: center;
}

.stats-label {
  display: block;
  font-size: 0.8rem;
  color: var(--light-text-color);
  margin-bottom: 5px;
}

.stats-value {
  font-weight: bold;
  font-size: 1.1rem;
}

/* セッション履歴 */
.session-history {
  max-height: 300px;
  overflow-y: auto;
  margin-top: 20px;
}

.session-history h3 {
  margin-bottom: 10px;
}

.session-history-list {
  list-style: none;
  padding: 0;
}

.history-date {
  margin-bottom: 15px;
}

.history-date h4 {
  margin-bottom: 5px;
  color: var(--primary-color);
}

.history-date ul {
  list-style: none;
  padding-left: 10px;
}

.history-item {
  padding: 5px 10px;
  margin-bottom: 5px;
  border-radius: 4px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  background-color: var(--light-gray);
  font-size: 0.9rem;
}

.history-item.work {
  border-left: 3px solid var(--pomodoro-work);
}

.history-item.shortBreak {
  border-left: 3px solid var(--pomodoro-short-break);
}

.history-item.longBreak {
  border-left: 3px solid var(--pomodoro-long-break);
}

.history-item.completed {
  font-weight: bold;
}

.history-type {
  min-width: 50px;
}

.history-time {
  flex: 1;
}

.history-duration {
  color: var(--light-text-color);
}

.history-cycle {
  font-size: 0.8rem;
  color: var(--light-text-color);
}

/* リマインダーパネル */
.reminder-panel {
  border-radius: 8px;
  margin-bottom: 20px;
  background-color: var(--reminder-bg);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
  border: 1px solid var(--reminder-border);
  overflow: hidden;
  transition: all 0.3s ease;
}

/* 今日のリマインダーがある場合に強調表示 */
.reminder-panel.has-reminders {
  box-shadow: 0 4px 12px rgba(243, 156, 18, 0.4);
  border: 1px solid var(--reminder-badge);
  animation: reminder-glow 2s infinite alternate;
}

@keyframes reminder-glow {
  from {
    box-shadow: 0 4px 12px rgba(243, 156, 18, 0.3);
  }
  to {
    box-shadow: 0 4px 15px rgba(243, 156, 18, 0.6);
  }
}

.reminder-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px;
  border-bottom: 1px solid var(--reminder-border);
  background: linear-gradient(to right, rgba(243, 156, 18, 0.1), transparent);
}

.reminder-header h3 {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.2rem;
  font-weight: bold;
}

.reminder-icon {
  font-size: 1.4rem;
  transition: all 0.3s ease;
}

/* 通知がある場合のアイコンアニメーション */
.reminder-icon.pulse {
  animation: bell-ring 1.5s infinite;
  color: var(--reminder-badge);
}

@keyframes bell-ring {
  0% { transform: rotate(0); }
  5% { transform: rotate(15deg); }
  10% { transform: rotate(-15deg); }
  15% { transform: rotate(10deg); }
  20% { transform: rotate(-10deg); }
  25% { transform: rotate(5deg); }
  30% { transform: rotate(-5deg); }
  35% { transform: rotate(0); }
  100% { transform: rotate(0); }
}

.reminder-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  background-color: var(--reminder-badge);
  color: white;
  border-radius: 50%;
  font-size: 0.9rem;
  font-weight: bold;
  margin-left: 5px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  animation: badge-pulse 2s infinite alternate;
}

@keyframes badge-pulse {
  from {
    transform: scale(1);
  }
  to {
    transform: scale(1.1);
  }
}

.reminder-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.reminder-settings-btn {
  background: none;
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  transition: all 0.2s ease;
}

.reminder-settings-btn:hover {
  background-color: rgba(0, 0, 0, 0.05);
  transform: rotate(30deg);
}

.reminder-toggle-btn {
  background: none;
  border: none;
  font-size: 1.1rem;
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  transition: background-color 0.2s ease;
}

.reminder-toggle-btn:hover {
  background-color: rgba(0, 0, 0, 0.05);
}

.reminder-content {
  padding: 15px;
  max-height: 400px;
  overflow-y: auto;
}

/* 折りたたまれた時のプレビュー表示 */
.reminder-preview {
  padding: 10px 15px;
  font-weight: bold;
  color: var(--reminder-badge);
  background-color: rgba(243, 156, 18, 0.1);
  font-size: 0.95rem;
  text-align: center;
}

.no-reminders {
  text-align: center;
  padding: 20px;
  color: var(--light-text-color);
}

.reminder-list {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.reminder-group-title {
  margin: 0 0 12px 0;
  font-size: 1.05rem;
  color: var(--text-color);
  padding-bottom: 8px;
  border-bottom: 1px solid var(--reminder-border);
  font-weight: bold;
}

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

.reminder-item {
  background-color: var(--card-background);
  border-radius: 8px;
  padding: 12px;
  border-left: 4px solid var(--primary-color);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}

.reminder-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.reminder-item.priority-high {
  border-left-color: var(--priority-high);
  background-color: rgba(231, 76, 60, 0.05);
}

.reminder-item.priority-normal {
  border-left-color: var(--primary-color);
}

.reminder-item.priority-low {
  border-left-color: var(--priority-low);
}

.reminder-item-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.reminder-type-icon {
  margin-right: 8px;
  font-size: 1.1rem;
}

.reminder-time {
  font-size: 0.9rem;
  color: var(--light-text-color);
  margin-right: auto;
  margin-left: 8px;
  font-weight: bold;
}

.reminder-delete-btn {
  background: none;
  border: none;
  color: var(--light-text-color);
  font-size: 1.2rem;
  cursor: pointer;
  padding: 4px 8px;
  line-height: 1;
  border-radius: 50%;
  transition: all 0.2s ease;
}

.reminder-delete-btn:hover {
  color: var(--danger-color);
  background-color: rgba(231, 76, 60, 0.1);
}

.reminder-item-content {
  padding-left: 25px;
}

.reminder-task-title {
  font-weight: bold;
  margin-bottom: 5px;
  font-size: 1rem;
}

.reminder-message {
  font-size: 0.95rem;
  color: var(--text-color);
  opacity: 0.9;
}

.reminder-footer {
  margin-top: 20px;
  text-align: center;
}

.add-reminder-btn {
  background-color: transparent;
  color: var(--primary-color);
  border: 1px solid var(--primary-color);
  padding: 8px 20px;
  border-radius: 20px;
  font-size: 0.95rem;
  font-weight: bold;
  transition: all 0.3s ease;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.add-reminder-btn:hover {
  background-color: var(--primary-color);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

/* タスク強調表示 */
.task-item.highlighted {
  animation: highlight-pulse 1.5s ease-in-out;
  border: 2px solid var(--primary-color);
}

@keyframes highlight-pulse {
  0% { box-shadow: 0 0 0 0 rgba(74, 134, 232, 0.4); }
  70% { box-shadow: 0 0 0 10px rgba(74, 134, 232, 0); }
  100% { box-shadow: 0 0 0 0 rgba(74, 134, 232, 0); }
}

/* リマインダー通知アニメーション */
.reminder-item.new {
  animation: slide-in 0.5s ease-out forwards;
}

@keyframes slide-in {
  0% { 
    opacity: 0;
    transform: translateY(-20px);
  }
  100% { 
    opacity: 1;
    transform: translateY(0);
  }
}

.reminder-badge {
  animation: reminder-pulse 2s infinite;
}

@keyframes reminder-pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.1); }
  100% { transform: scale(1); }
}

/* キーボードショートカットヘルプモーダル */
.keyboard-help-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.keyboard-help-modal .modal-content {
  background-color: var(--card-background);
  padding: 20px;
  border-radius: 8px;
  width: 90%;
  max-width: 700px;
  max-height: 90vh;
  overflow-y: auto;
  transform: translateY(0);
  transition: transform 0.3s ease;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.shortcuts-container {
  max-height: 60vh;
  overflow-y: auto;
  margin-bottom: 20px;
  padding-right: 10px;
}

.shortcuts-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 15px;
}

.shortcuts-table th,
.shortcuts-table td {
  padding: 8px 12px;
  border-bottom: 1px solid var(--border-color);
  text-align: left;
}

.shortcuts-table th {
  font-weight: bold;
  background-color: var(--light-gray);
}

.shortcuts-table tr:hover {
  background-color: var(--light-gray);
}

kbd {
  display: inline-block;
  background-color: var(--light-gray);
  border: 1px solid var(--border-color);
  border-radius: 4px;
  box-shadow: 0 2px 3px rgba(0, 0, 0, 0.2);
  font-family: monospace;
  font-size: 0.9em;
  padding: 3px 8px;
  margin: 0 2px;
  white-space: nowrap;
  color: var(--text-color);
}

/* データエクスポート・インポート関連のスタイル */
.data-export-modal .modal-content,
.data-import-modal .modal-content,
.backup-modal .modal-content {
  max-width: 600px;
}

.backup-modal-content {
  max-height: 80vh;
  overflow-y: auto;
}

.format-options,
.mode-option {
  margin-bottom: 15px;
}

.format-option,
.mode-option {
  margin-bottom: 10px;
  padding: 8px;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  transition: background-color 0.2s;
}

.format-option:hover,
.mode-option:hover {
  background-color: var(--light-gray);
}

.format-option input,
.mode-option input {
  margin-right: 10px;
}

.format-name,
.mode-name {
  font-weight: bold;
  display: block;
}

.format-description,
.mode-description {
  font-size: 0.85em;
  color: var(--light-text-color);
  display: block;
  margin-top: 5px;
}

.file-upload-container {
  margin: 20px 0;
}

.file-upload-label {
  display: inline-block;
  padding: 8px 16px;
  background-color: var(--primary-color);
  color: white;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.file-upload-label:hover {
  background-color: rgba(74, 134, 232, 0.8);
}

.file-upload-icon {
  margin-right: 8px;
}

input[type="file"] {
  display: none;
}

.file-name-display {
  margin-top: 10px;
  padding: 8px;
  background-color: var(--light-gray);
  border-radius: 4px;
  word-break: break-all;
}

.backup-actions {
  margin-bottom: 20px;
}

.auto-backup-settings {
  margin-bottom: 20px;
  padding: 15px;
  background-color: var(--light-gray);
  border-radius: 4px;
}

.settings-group {
  margin-top: 10px;
}

.setting-row {
  display: flex;
  align-items: center;
  margin-bottom: 10px;
}

.setting-label {
  margin-left: 10px;
}

.toggle-switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 24px;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  border-radius: 34px;
  transition: .4s;
}

.toggle-slider:before {
  position: absolute;
  content: "";
  height: 16px;
  width: 16px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  border-radius: 50%;
  transition: .4s;
}

input:checked + .toggle-slider {
  background-color: var(--primary-color);
}

input:checked + .toggle-slider:before {
  transform: translateX(26px);
}

.backup-list-container {
  margin-top: 20px;
}

.backup-list {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
}

.backup-list th,
.backup-list td {
  padding: 10px;
  text-align: left;
  border-bottom: 1px solid var(--border-color);
}

.backup-list th {
  background-color: var(--light-gray);
}

.backup-list tr:hover {
  background-color: var(--light-gray);
}

.restore-backup-btn,
.export-backup-btn {
  padding: 4px 8px;
  font-size: 0.85rem;
  margin-right: 5px;
}

.restore-backup-btn {
  background-color: var(--secondary-color);
}

.export-backup-btn {
  background-color: var(--primary-color);
}

/* レスポンシブデザイン */
@media (max-width: 960px) {
  .container {
    width: 98%;
    padding: 15px;
  }
  
  /* ダッシュボードレイアウト */
  .dashboard-row,
  .dashboard-detail-row {
    flex-direction: column;
  }
  
  .dashboard-card,
  .dashboard-card.wide {
    min-width: 100%;
    margin-bottom: 15px;
  }
}

@media (max-width: 768px) {
  body {
    padding: 10px;
  }
  
  .container {
    border-radius: 6px;
    padding: 12px;
  }
  
  .task-header {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .task-actions {
    margin-top: 10px;
    width: 100%;
    justify-content: flex-end;
  }
  
  .task-meta {
    flex-direction: column;
    gap: 5px;
  }
  
  .import-export {
    margin-top: 15px;
    width: 100%;
  }
  
  .stats-details,
  .work-time-detail {
    flex-direction: column;
    gap: 15px;
  }
  
  .pomodoro-controls {
    flex-wrap: wrap;
  }
  
  .pomodoro-controls button {
    flex: 1;
    min-width: 120px;
  }
  
  .history-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
  }
  
  .reminder-item-header {
    flex-wrap: wrap;
  }
  
  /* フォーム要素 */
  .form-row {
    flex-direction: column !important;
  }
  
  .form-group.half {
    width: 100% !important;
  }
}

@media (max-width: 480px) {
  body {
    padding: 5px;
  }
  
  .container {
    width: 100%;
    padding: 10px;
    border-radius: 4px;
  }
  
  h1 {
    font-size: 1.5rem;
  }
  
  .header-controls {
    gap: 5px;
  }
  
  .icon-btn {
    font-size: 1.2rem;
    padding: 3px;
  }
  
  /* ダッシュボードパネル */
  .dashboard-btn {
    width: 100%;
  }
  
  /* タスクリスト */
  .task-item {
    padding: 10px;
  }
  
  .task-actions {
    flex-direction: column;
    width: 100%;
    align-items: stretch;
  }
  
  .task-actions button {
    margin-bottom: 5px;
    width: 100%;
    text-align: center;
  }
  
  /* フォームボタン */
  .form-actions {
    flex-direction: column;
    gap: 10px;
  }
  
  .form-actions button {
    width: 100%;
  }
  
  /* フローティングボタン */
  #add-task-button {
    font-size: 0.9rem;
    padding: 10px 16px;
  }
}

/* アプリ内通知のスタイル */
.in-app-notification {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background-color: var(--card-background);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  border-radius: 8px;
  padding: 15px;
  z-index: 9999;
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 350px;
  width: calc(100% - 40px);
  transition: all 0.3s ease;
  border-left: 4px solid var(--primary-color);
  animation: notification-fade-in 0.3s forwards;
}

@keyframes notification-fade-in {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.in-app-notification.priority-high {
  border-left-color: var(--priority-high);
  background-color: rgba(231, 76, 60, 0.05);
  animation: high-priority-pulse 2s infinite alternate;
}

@keyframes high-priority-pulse {
  from {
    box-shadow: 0 4px 12px rgba(231, 76, 60, 0.3);
  }
  to {
    box-shadow: 0 4px 15px rgba(231, 76, 60, 0.6);
  }
}

.in-app-notification.priority-low {
  border-left-color: var(--priority-low);
}

.notification-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
}

.in-app-notification.priority-high .notification-icon {
  color: var(--priority-high);
  animation: icon-pulse 1s infinite;
}

@keyframes icon-pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.2); }
  100% { transform: scale(1); }
}

.notification-content {
  flex: 1;
  min-width: 0;
}

.notification-title {
  font-weight: bold;
  margin-bottom: 5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.notification-message {
  font-size: 0.95rem;
  color: var(--light-text-color);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.notification-close-btn {
  background: transparent;
  border: none;
  color: var(--light-text-color);
  font-size: 1.2rem;
  cursor: pointer;
  padding: 5px;
  border-radius: 50%;
  transition: all 0.2s ease;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
}

.notification-close-btn:hover {
  background-color: rgba(0, 0, 0, 0.1);
  color: var(--danger-color);
}

/* タブレット・モバイル対応 */
@media (max-width: 768px) {
  .in-app-notification {
    bottom: 10px;
    right: 10px;
    max-width: calc(100% - 20px);
    padding: 12px;
  }
  
  /* ポモドーロウィジェットのレスポンシブ対応 */
  .pomodoro-widget.widget-mode {
    top: 10px;
    right: 10px;
    width: 240px;
  }
  
  .pomodoro-widget.widget-mode .pomodoro-timer {
    font-size: 2rem;
  }
  
  .pomodoro-widget.widget-mode .pomodoro-controls {
    flex-wrap: wrap;
    gap: 5px;
  }
  
  .pomodoro-widget.widget-mode .pomodoro-controls button {
    padding: 5px 10px;
    font-size: 0.8rem;
  }
  
  .pomodoro-widget.collapsed {
    width: auto;
    max-width: 130px;
  }
  
  .pomodoro-widget.collapsed .pomodoro-timer {
    font-size: 1.1rem;
  }
}

@media (max-width: 480px) {
  .pomodoro-widget.widget-mode {
    width: auto;
    max-width: 85%;
  }
  
  .pomodoro-widget.widget-mode .pomodoro-timer {
    font-size: 1.8rem;
  }
  
  .pomodoro-widget.collapsed {
    width: auto;
    max-width: 120px;
  }
  
  .pomodoro-widget.collapsed .pomodoro-timer {
    font-size: 1rem;
  }
  
  /* スマホでは折りたたみ時に特別なスタイル */
  .pomodoro-widget.collapsed .pomodoro-header h3 {
    font-size: 0.9rem;
  }
}