/* 基础重置 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  background: #FAFAFA;
  min-height: 100vh;
}

.container {
  max-width: 500px;
  margin: 0 auto;
  padding: 12px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ========== 顶部导航 ========== */
.header {
  background: linear-gradient(135deg, #FF6B35, #FF5722);
  color: #fff;
  text-align: center;
  padding: 16px;
  margin: -12px -12px 12px -12px;
}

.header h1 {
  font-size: 18px;
  font-weight: 500;
}

/* ========== 工具栏 ========== */
.toolbar {
  display: flex;
  align-items: center;
  padding: 10px 12px;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.04);
}

.location-selector {
  display: flex;
  align-items: center;
  flex: 1;
  min-width: 0;
  cursor: pointer;
}

.location-dot {
  width: 8px;
  height: 8px;
  background: #FF6B35;
  border-radius: 50%;
  margin-right: 6px;
  flex-shrink: 0;
}

.location-text {
  font-size: 14px;
  color: #1A1A1A;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 150px;
}

.arrow-down {
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 5px solid #999;
  margin-left: 5px;
  flex-shrink: 0;
}

.radius-selector {
  margin-left: 8px;
}

.radius-selector select {
  padding: 6px 12px;
  background: #F5F5F5;
  border: none;
  border-radius: 12px;
  font-size: 13px;
  color: #666;
  cursor: pointer;
  outline: none;
}

.relocate-btn {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-left: 8px;
  flex-shrink: 0;
  background: #F5F5F5;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  transition: background 0.2s;
}

.relocate-btn:hover {
  background: #EBEBEB;
}

.relocate-btn:active {
  background: #E0E0E0;
}

.relocate-icon {
  width: 20px;
  height: 20px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gps-circle {
  width: 16px;
  height: 16px;
  border: 2px solid #666;
  border-radius: 50%;
  position: relative;
}

.gps-circle::before {
  content: '';
  position: absolute;
  top: 50%;
  left: -5px;
  right: -5px;
  height: 2px;
  background: #666;
  transform: translateY(-50%);
}

.gps-circle::after {
  content: '';
  position: absolute;
  left: 50%;
  top: -5px;
  bottom: -5px;
  width: 2px;
  background: #666;
  transform: translateX(-50%);
}

.gps-dot {
  position: absolute;
  width: 6px;
  height: 6px;
  background: #FF6B35;
  border-radius: 50%;
}

/* ========== 核心操作按钮 ========== */
.action-section {
  display: flex;
  justify-content: center;
  padding: 16px 0;
}

.action-section.center {
  flex: 1;
  align-items: center;
  padding: 0;
}

.action-section.bottom {
  padding: 16px 0 8px;
}

.spin-btn {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  background: linear-gradient(145deg, #FF7B45, #FF5722);
  box-shadow: 0 6px 20px rgba(255, 107, 53, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.spin-btn:hover {
  transform: scale(1.02);
}

.spin-btn:active {
  transform: scale(0.95);
  box-shadow: 0 3px 10px rgba(255, 107, 53, 0.4);
}

.spin-btn.spinning {
  animation: pulse 0.8s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

.spin-text {
  font-size: 16px;
  color: #fff;
  font-weight: 600;
  letter-spacing: 2px;
}

/* ========== 错误提示 ========== */
.error-card {
  background: #fff;
  border-radius: 8px;
  padding: 20px;
  text-align: center;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.04);
  margin-top: 12px;
}

.error-text {
  font-size: 14px;
  color: #666;
  display: block;
  margin-bottom: 15px;
}

.retry-btn {
  display: inline-block;
  padding: 8px 24px;
  background: #FF6B35;
  border-radius: 16px;
  border: none;
  color: #fff;
  font-size: 14px;
  cursor: pointer;
}

.retry-btn:hover {
  background: #FF5722;
}

/* ========== 餐厅卡片 ========== */
.restaurant-card {
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
  margin-top: 12px;
}

.photo-section {
  width: 100%;
  height: 160px;
  overflow: hidden;
}

.restaurant-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-placeholder {
  width: 100%;
  height: 100px;
  background: linear-gradient(135deg, #F8F8F8 0%, #EFEFEF 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.placeholder-text {
  font-size: 13px;
  color: #CCC;
}

.card-content {
  padding: 12px;
}

.restaurant-name {
  font-size: 18px;
  font-weight: 600;
  color: #1A1A1A;
  line-height: 1.3;
  margin-bottom: 6px;
}

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

.type-tag {
  font-size: 11px;
  color: #FF6B35;
  background: #FFF5F2;
  padding: 2px 6px;
  border-radius: 3px;
}

.meta-dot {
  font-size: 11px;
  color: #DDD;
  margin: 0 5px;
}

.distance {
  font-size: 11px;
  color: #999;
}

.rating {
  font-size: 11px;
  color: #FF9500;
}

.cost {
  font-size: 11px;
  color: #666;
}

/* ========== 地图区域 ========== */
.map-section {
  position: relative;
  width: 100%;
  height: 140px;
  border-radius: 6px;
  overflow: hidden;
  margin-bottom: 8px;
  cursor: pointer;
}

.restaurant-map {
  width: 100%;
  height: 100%;
}

.map-hint {
  position: absolute;
  bottom: 6px;
  right: 6px;
  background: rgba(0, 0, 0, 0.6);
  padding: 3px 8px;
  border-radius: 8px;
}

.map-hint span {
  font-size: 10px;
  color: #fff;
}

/* ========== 详细信息 ========== */
.info-section {
  padding-top: 8px;
  border-top: 1px solid #F0F0F0;
}

.info-item {
  display: flex;
  align-items: flex-start;
  padding: 5px 0;
}

.info-item.clickable {
  cursor: pointer;
}

.info-item.clickable:hover {
  opacity: 0.7;
}

.info-label {
  font-size: 12px;
  color: #999;
  width: 35px;
  flex-shrink: 0;
}

.info-value {
  font-size: 12px;
  color: #333;
  flex: 1;
  line-height: 1.5;
}

.info-value.phone {
  color: #FF6B35;
  text-decoration: none;
}

/* ========== 响应式适配 ========== */
@media (max-width: 375px) {
  .location-text {
    max-width: 120px;
  }
}
