/**
 * check-in-map.css
 * チェックインマップ表示スタイル
 */

.check-in-info-window {
  min-width: 280px;
  max-width: 320px;
  font-family: 'Noto Sans JP', sans-serif;
}

.check-in-info__header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid #e0e0e0;
}

.check-in-info__avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #ff6b35;
}

.check-in-info__user {
  flex: 1;
}

.check-in-info__user-name {
  font-size: 15px;
  font-weight: 600;
  color: #212121;
  margin-bottom: 2px;
}

.check-in-info__time {
  font-size: 12px;
  color: #757575;
}

.check-in-info__place {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 600;
  color: #424242;
  margin-bottom: 12px;
}

.check-in-info__place i {
  color: #ff6b35;
  font-size: 16px;
}

.check-in-info__comment {
  font-size: 13px;
  color: #424242;
  line-height: 1.5;
  margin-bottom: 12px;
  padding: 8px 12px;
  background: #f8f9fa;
  border-radius: 8px;
  font-style: italic;
}

.check-in-info__image {
  width: 100%;
  height: auto;
  max-height: 200px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 12px;
}

.check-in-info__points {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  background: linear-gradient(135deg, #ffd700 0%, #ff6b35 100%);
  color: white;
  font-size: 13px;
  font-weight: 700;
  border-radius: 8px;
}

.check-in-info__points i {
  font-size: 14px;
}

.map-controls {
  position: absolute;
  top: 80px;
  right: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 10;
}

.map-control-btn {
  padding: 12px;
  background: white;
  border: 2px solid #e0e0e0;
  border-radius: 12px;
  cursor: pointer;
  font-size: 20px;
  color: #424242;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.map-control-btn:hover:not(:disabled) {
  background: #f5f5f5;
  border-color: #ff6b35;
  color: #ff6b35;
  transform: scale(1.05);
}

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

.map-control-btn.active {
  background: linear-gradient(135deg, #ff6b35 0%, #ffb199 100%);
  border-color: #ff6b35;
  color: white;
}

.map-timeframe-selector {
  position: absolute;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  background: white;
  padding: 8px;
  border-radius: 12px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
  z-index: 10;
}

.timeframe-btn {
  padding: 8px 16px;
  background: transparent;
  border: none;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  color: #757575;
  cursor: pointer;
  transition: all 0.2s ease;
}

.timeframe-btn:hover {
  background: #f5f5f5;
  color: #424242;
}

.timeframe-btn.active {
  background: linear-gradient(135deg, #ff6b35 0%, #ffb199 100%);
  color: white;
  box-shadow: 0 2px 8px rgba(255, 107, 53, 0.3);
}

.map-legend {
  position: absolute;
  bottom: 24px;
  left: 12px;
  background: white;
  padding: 12px 16px;
  border-radius: 12px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
  z-index: 10;
}

.map-legend__title {
  font-size: 13px;
  font-weight: 700;
  color: #212121;
  margin-bottom: 8px;
}

.map-legend__items {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.map-legend__item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: #424242;
}

.map-legend__color {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid white;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
}

.map-legend__color.recent {
  background: #ff6b35;
}

.map-legend__color.today {
  background: #ffa500;
}

.map-legend__color.older {
  background: #4ecdc4;
}

/* ==========================================================================
   ダークモード対応
   ========================================================================== */

[data-theme='dark'] .check-in-info__header {
  border-bottom-color: var(--color-border, #333333);
}

[data-theme='dark'] .check-in-info__user-name {
  color: var(--color-text, #ffffff);
}

[data-theme='dark'] .check-in-info__time {
  color: var(--color-text-secondary, #b3b3b3);
}

[data-theme='dark'] .check-in-info__place {
  color: var(--color-text, #ffffff);
}

[data-theme='dark'] .check-in-info__comment {
  background: var(--color-surface-light, #2c2c2c);
  color: var(--color-text, #ffffff);
}

[data-theme='dark'] .map-control-btn {
  background: var(--color-surface, #1e1e1e);
  border-color: var(--color-border, #333333);
  color: var(--color-text, #ffffff);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

[data-theme='dark'] .map-control-btn:hover:not(:disabled) {
  background: var(--color-surface-light, #2c2c2c);
}

[data-theme='dark'] .map-timeframe-selector {
  background: var(--color-surface, #1e1e1e);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
}

[data-theme='dark'] .timeframe-btn {
  color: var(--color-text-secondary, #b3b3b3);
}

[data-theme='dark'] .timeframe-btn:hover {
  background: var(--color-surface-light, #2c2c2c);
  color: var(--color-text, #ffffff);
}

[data-theme='dark'] .map-legend {
  background: var(--color-surface, #1e1e1e);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
}

[data-theme='dark'] .map-legend__title {
  color: var(--color-text, #ffffff);
}

[data-theme='dark'] .map-legend__item {
  color: var(--color-text-secondary, #b3b3b3);
}

[data-theme='dark'] .map-legend__color {
  border-color: var(--color-surface, #1e1e1e);
}

@media (max-width: 768px) {
  .check-in-info-window {
    min-width: 240px;
    max-width: 280px;
  }

  .map-controls {
    top: 60px;
    right: 8px;
  }

  .map-control-btn {
    padding: 10px;
    font-size: 18px;
  }

  .map-timeframe-selector {
    top: 8px;
    flex-wrap: wrap;
    max-width: calc(100% - 16px);
  }

  .timeframe-btn {
    padding: 6px 12px;
    font-size: 12px;
  }

  .map-legend {
    bottom: 16px;
    left: 8px;
    padding: 10px 12px;
  }
}

@media (max-width: 576px) {
  .check-in-info__avatar {
    width: 40px;
    height: 40px;
  }

  .check-in-info__user-name {
    font-size: 14px;
  }

  .check-in-info__image {
    max-height: 160px;
  }
}
