* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "PingFang SC", "Microsoft YaHei", sans-serif;
}

body {
  background-color: #2c3e50; /* 默认背景色，以防背景图片加载失败 */
  background-image: linear-gradient(135deg, #3498db, #9b59b6);
  background-size: cover;
  height: 100vh;
  width: 100%;
  overflow: hidden;
  color: #fff;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  padding: 20px;
  overflow-y: auto;
  max-height: 100vh;
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE/Edge */
}

.container::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none; /* Chrome, Safari, Opera */
}

.search-container {
  margin: 0 auto 40px;
  width: 60%;
}

.search-box {
  display: flex;
  align-items: center;
  background-color: rgba(255, 255, 255, 0.9);
  border-radius: 24px;
  padding: 10px 15px;
}

.search-icon {
  width: 24px;
  height: 24px;
  margin-right: 10px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-weight: bold;
  border-radius: 50%;
}

.baidu-icon {
  background-color: #3385ff;
  color: white;
  font-size: 12px;
}

.baidu-icon::before {
  content: "百";
}

.search-box input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-size: 16px;
  color: #333;
}

.bookmarks-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-top: 50px;
}

.bookmarks-row {
  display: flex;
  justify-content: center;
}

.bookmark-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 120px;
  cursor: pointer;
  transition: transform 0.2s ease;
}

.bookmark-item:hover {
  transform: scale(1.05);
}

.bookmark-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background-color: #fff;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 10px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  font-weight: bold;
  font-size: 24px;
  color: white;
}

.bookmark-icon img {
  width: 60%;
  height: 60%;
  object-fit: contain;
}

.bookmark-title {
  font-size: 12px;
  white-space: nowrap;
  text-align: center;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.weather {
  color: white;
  font-size: 16px;
  font-weight: bold;
}

.todo {
  background-color: #34a853;
}

.notes {
  background-color: #fbbc05;
  color: #333;
}

.settings {
  background-color: #a1a1a1;
}

.jd {
  background-color: #e33333;
}

.tmall {
  background-color: #ff0036;
}

.taobao {
  background-color: #ff5000;
}

.vip {
  background-color: #f10180;
}

.design {
  background-color: #5e33ff;
}

.baidu {
  background-color: #3385ff;
}

.ad {
  background-color: #b4a078;
}

.travel {
  background-color: #09b9f2;
}

.math {
  background-color: #d92b2f;
}

.iqiyi {
  background-color: #1ba048;
}

.bilibili {
  background-color: #fb7299;
}

.games {
  background-color: #a4c5fc;
  color: #333;
}

.infinity {
  background-color: #333;
  font-size: 32px;
}

.wallpaper {
  background-color: #8a56d6;
}

.pagination {
  display: none !important;
}

.dot {
  display: none !important;
}

/* 设置面板样式 */
.settings-panel {
  position: fixed;
  top: 0;
  right: -360px; /* 初始隐藏在右侧 */
  width: 360px;
  height: 100%;
  background-color: white;
  box-shadow: -2px 0 10px rgba(0, 0, 0, 0.2);
  color: #333;
  transition: right 0.3s ease;
  z-index: 1000;
  overflow-y: auto;
}

.settings-panel.active {
  right: 0; /* 显示面板 */
}

.settings-header {
  display: flex;
  align-items: center;
  padding: 15px 20px;
  border-bottom: 1px solid #eee;
  position: relative;
}

.settings-header h2 {
  flex: 1;
  text-align: center;
  font-size: 18px;
  margin: 0;
}

.close-btn {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: #666;
}

.settings-tabs {
  display: flex;
  border-bottom: 1px solid #eee;
}

.tab-btn {
  flex: 1;
  padding: 12px;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 14px;
  color: #666;
  border-bottom: 3px solid transparent;
  transition: all 0.2s ease;
}

.tab-btn.active {
  color: #3498db;
  border-bottom-color: #3498db;
  font-weight: bold;
}

.settings-content {
  overflow-y: auto;
  padding: 20px;
}

.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

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

.form-group label {
  display: block;
  margin-bottom: 5px;
  font-size: 14px;
  color: #555;
}

.form-group input[type="text"],
.form-group input[type="url"],
.form-group select {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 14px;
}

.form-group input[type="color"] {
  width: 50px;
  height: 30px;
  border: 1px solid #ddd;
  border-radius: 4px;
  vertical-align: middle;
}

.btn-primary,
.btn-secondary {
  padding: 8px 16px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
  margin-right: 10px;
  transition: background-color 0.2s ease;
}

.btn-primary {
  background-color: #3498db;
  color: white;
}

.btn-primary:hover {
  background-color: #2980b9;
}

.btn-secondary {
  background-color: #eee;
  color: #333;
}

.btn-secondary:hover {
  background-color: #ddd;
}

.bookmark-list {
  margin-top: 15px;
  border: 1px solid #eee;
  border-radius: 4px;
  padding: 10px;
  min-height: 100px;
}

.background-preview {
  margin-top: 10px;
  width: 100%;
  height: 120px;
  border: 1px solid #ddd;
  border-radius: 4px;
  background-size: cover;
  background-position: center;
}

/* 自定义书签列表样式 */
.custom-bookmark-list {
  list-style: none;
  padding: 0;
}

.custom-bookmark {
  display: flex;
  align-items: center;
  padding: 8px;
  margin-bottom: 8px;
  background-color: #f9f9f9;
  border-radius: 4px;
  transition: background-color 0.2s ease;
}

.custom-bookmark:hover {
  background-color: #f0f0f0;
}

.bookmark-color {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  font-weight: bold;
  color: white;
  margin-right: 12px;
  flex-shrink: 0;
}

.bookmark-info {
  flex: 1;
  overflow: hidden;
}

.bookmark-name {
  font-weight: bold;
  color: #333;
  margin-bottom: 3px;
}

.bookmark-url {
  font-size: 12px;
  color: #666;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.delete-bookmark {
  background: none;
  border: none;
  color: #999;
  font-size: 18px;
  cursor: pointer;
  width: 24px;
  height: 24px;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 50%;
  transition: all 0.2s ease;
}

.delete-bookmark:hover {
  background-color: #ff5252;
  color: white;
}

/* Google和Bing搜索图标 */
.google-icon {
  background-color: #4285f4;
  color: white;
}

.bing-icon {
  background-color: #008373;
  color: white;
}

/* 天气面板样式 */
.weather-panel {
  position: fixed;
  top: 0;
  right: -400px; /* 初始隐藏在右侧 */
  width: 400px;
  height: 100%;
  background-color: white;
  box-shadow: -2px 0 10px rgba(0, 0, 0, 0.2);
  color: #333;
  transition: right 0.3s ease;
  z-index: 1000;
  overflow-y: auto;
}

.weather-panel.active {
  right: 0; /* 显示面板 */
}

.weather-header {
  display: flex;
  align-items: center;
  padding: 15px 20px;
  border-bottom: 1px solid #eee;
  position: relative;
}

.weather-header h2 {
  flex: 1;
  text-align: center;
  font-size: 18px;
  margin: 0;
}

.weather-content {
  padding: 20px;
}

.weather-update-time {
  color: #666;
  font-size: 12px;
  margin-bottom: 20px;
}

.current-weather {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #4285f4;
  border-radius: 10px;
  padding: 20px;
  color: white;
  margin-bottom: 20px;
}

.city-info {
  display: flex;
  flex-direction: column;
}

.city-info h3 {
  margin: 0 0 10px 0;
  font-size: 24px;
}

.weather-condition {
  display: flex;
  align-items: center;
}

.weather-icon {
  width: 40px;
  height: 40px;
  margin-right: 10px;
  object-fit: contain; /* 确保保持图标比例 */
}

.temperature {
  font-size: 72px;
  font-weight: 300;
  line-height: 1;
  margin-left: 20px;
}

.degree-symbol {
  position: relative;
  top: -20px;
  font-size: 40px;
}

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

.city-list {
  margin-top: 20px;
}

.city-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px;
  border-bottom: 1px solid #eee;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.city-item:hover {
  background-color: #f5f5f5;
}

.city-item.active {
  background-color: #f0f7ff;
}

.city-name {
  font-size: 16px;
  font-weight: 500;
}

.city-temp {
  font-size: 18px;
  font-weight: 600;
}

.add-city-form {
  margin-top: 20px;
  border-top: 1px solid #eee;
  padding-top: 20px;
}

.add-city-form h3 {
  margin-top: 0;
  margin-bottom: 15px;
  font-size: 16px;
}

.search-results {
  margin-top: 15px;
}

.search-result-item {
  padding: 10px;
  border-bottom: 1px solid #eee;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.search-result-item:hover {
  background-color: #f5f5f5;
}

/* 添加时间显示样式 */
.time-display {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 40px 0 20px;
  margin-bottom: 20px;
}

#current-time {
  font-size: 6rem;
  font-weight: 200;
  color: white;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  letter-spacing: 2px;
}

/* 菜单图标样式 */
.menu-icon {
  position: fixed;
  top: 20px;
  right: 20px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  z-index: 1001;
  transition: background-color 0.2s ease;
}

.menu-icon:hover {
  background-color: rgba(0, 0, 0, 0.8);
}

.menu-line {
  width: 20px;
  height: 2px;
  background-color: white;
  border-radius: 1px;
}

/* 应用分类样式 */
.app-categories {
  width: 100%;
  max-width: 1200px;
  padding: 20px 20px 0px 20px;
  overflow-y: visible;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.category-group {
  margin-bottom: 30px;
}

.category-title {
  color: white;
  font-size: 18px;
  margin-bottom: 15px;
  font-weight: 500;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.app-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 20px;
  justify-content: center;
  margin-bottom: 25px;
  overflow-x: visible;
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE/Edge */
}

.app-grid::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none; /* Chrome, Safari, Opera */
}

.app-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  cursor: pointer;
  transition: transform 0.2s ease;
  padding-top: 10px;
  position: relative;
}

.app-item:hover {
  transform: scale(1.05);
}

.app-icon {
  width: 60px;
  height: 60px;
  border-radius: 15px;
  background-color: #fff;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
  font-weight: 600;
  font-size: 18px;
  color: white;
}

.app-name {
  font-size: 12px;
  text-align: center;
  color: white;
  max-width: 80px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* 响应式设计 */
@media (min-width: 1500px) {
  .app-grid {
    grid-template-columns: repeat(8, 1fr);
  }
}

@media (max-width: 1200px) {
  .app-grid {
    grid-template-columns: repeat(6, minmax(60px, 1fr));
    gap: 15px;
  }
}

@media (max-width: 900px) {
  .app-grid {
    grid-template-columns: repeat(5, minmax(50px, 1fr));
    gap: 10px;
  }
  
  .app-icon {
    width: 50px;
    height: 50px;
  }
}

@media (max-width: 768px) {
  .app-grid {
    grid-template-columns: repeat(4, minmax(40px, 1fr));
    gap: 10px;
  }
  
  .app-icon {
    width: 40px;
    height: 40px;
    font-size: 14px;
  }
  
  .app-name {
    font-size: 10px;
  }
}

/* 右上角天气图标样式 */
.weather-icon-top {
  position: fixed;
  top: 20px;
  right: 120px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 14px;
  font-weight: bold;
  color: white;
  z-index: 1001;
  cursor: pointer;
  transition: transform 0.2s ease;
}

.weather-icon-top:hover {
  transform: scale(1.05);
}
/* 添加网站按钮样式 */
.add-website-icon-top {
  position: fixed;
  top: 20px;
  right: 70px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  font-size: 24px;
  color: white;
  z-index: 1001;
  cursor: pointer;
  transition: transform 0.2s ease, background-color 0.2s ease;
  border: 1px solid rgba(247, 243, 243, 0.1);
}

.add-website-icon-top:hover {
  transform: scale(1.05);
  background-color: rgba(12, 12, 12, 0.5);
  border: 0px solid rgba(247, 243, 243, 0.1);
}
/* 应用网格调整 */
@media (min-width: 768px) {
  .app-grid {
    grid-template-columns: repeat(8, minmax(60px, 1fr));
  }
}

/* 调整分类组间距 */
.category-group {
  margin-bottom: 30px;
}

/* 更多响应式设计调整 */
@media (max-height: 900px) {
  .category-title {
    margin-bottom: 10px;
    font-size: 16px;
  }
  
  .app-grid {
    gap: 15px;
  }
  
  .app-icon {
    width: 50px;
    height: 50px;
    margin-bottom: 5px;
  }
  
  .category-group {
    margin-bottom: 10px;
  }
}

@media (max-height: 700px) {
  .container {
    padding: 10px;
  }
  
  .time-display {
    padding: 20px 0 10px;
    margin-bottom: 10px;
  }
  
  #current-time {
    font-size: 4rem;
  }
  
  .search-container {
    margin-bottom: 20px;
  }
}

/* 网站管理面板样式 */
.website-panel {
  position: fixed;
  top: 0;
  right: -400px; /* 初始隐藏在右侧 */
  width: 400px;
  height: 100%;
  background-color: white;
  box-shadow: -2px 0 10px rgba(0, 0, 0, 0.2);
  color: #333;
  transition: right 0.3s ease;
  z-index: 1000;
  overflow-y: auto;
}

.website-panel.active {
  right: 0; /* 显示面板 */
}

.website-header {
  display: flex;
  align-items: center;
  padding: 15px 20px;
  border-bottom: 1px solid #eee;
  position: relative;
}

.website-header h2 {
  flex: 1;
  text-align: center;
  font-size: 18px;
  margin: 0;
}

.website-content {
  padding: 20px;
}

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

.website-list {
  margin-top: 20px;
}

.website-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px;
  border-bottom: 1px solid #eee;
  transition: background-color 0.2s ease;
}

.website-item:hover {
  background-color: #f5f5f5;
}

.website-info {
  display: flex;
  align-items: center;
  flex: 1;
}

.website-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-weight: bold;
  color: white;
  margin-right: 15px;
  flex-shrink: 0;
}

.website-details {
  flex: 1;
  overflow: hidden;
}

.website-name {
  font-weight: bold;
  color: #333;
  margin-bottom: 5px;
}

.website-url {
  font-size: 12px;
  color: #666;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 3px;
}

.website-category {
  font-size: 11px;
  color: #999;
  background-color: #f0f0f0;
  padding: 2px 6px;
  border-radius: 10px;
  display: inline-block;
}

.website-controls {
  display: flex;
  gap: 10px;
}

.edit-website, 
.delete-website {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 18px;
  width: 30px;
  height: 30px;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 50%;
  transition: all 0.2s ease;
}

.edit-website:hover {
  background-color: #e3f2fd;
}

.delete-website:hover {
  background-color: #ffebee;
}

.add-website-form,
.edit-website-form {
  margin-top: 20px;
  border-top: 1px solid #eee;
  padding-top: 20px;
}

.add-website-form h3,
.edit-website-form h3 {
  margin-top: 0;
  margin-bottom: 15px;
  font-size: 16px;
}

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

.empty-message {
  color: #999;
  text-align: center;
  margin: 30px 0;
  font-style: italic;
}

/* iOS风格的应用编辑模式 */
.app-item {
  position: relative;
}

.app-icon-controls {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  height: 100%;
  display: none;
  z-index: 5;
}

.app-item:hover .app-icon-controls {
  display: block;
}

.app-delete-btn {
  position: absolute;
  top: 3px;
  left: 33px;
  width: 15px;
  height: 15px;
  background-color: #ffffff;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #000000;
  font-size: 16px;
  font-weight: normal;
  color: #999;
  z-index: 10;
  cursor: pointer;
  border: 1px solid rgba(0, 0, 0, 0.1);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  transform: scale(0);
  transition: transform 0.15s ease;
}

.app-delete-btn::before {
  content: "×";
  position: relative;
  top: -1px;
}

.app-edit-btn {
  position: absolute;
  top: 3px;
  right: 33px;
  width: 15px;
  height: 15px;
  background-color: #007aff;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  color: white;
  font-size: 12px;
  z-index: 10;
  cursor: pointer;
  border: 1px solid rgba(0, 0, 0, 0.1);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  transform: scale(0);
  transition: transform 0.15s ease;
}

.app-item:hover .app-delete-btn,
.app-item:hover .app-edit-btn {
  transform: scale(1);
}

.app-item.edit-mode .app-icon {
  animation: wiggle 0.5s infinite;
}

.custom-website .app-icon-controls {
  opacity: 0;
  transition: opacity 0.2s ease;
}

.custom-website:hover .app-icon-controls {
  opacity: 1;
}

@keyframes wiggle {
  0% { transform: rotate(0deg); }
  25% { transform: rotate(-3deg); }
  50% { transform: rotate(0deg); }
  75% { transform: rotate(3deg); }
  100% { transform: rotate(0deg); }
}

/* 常用网站区域样式 */
.error-message {
  color: #ff5252;
  text-align: center;
  margin: 30px 0;
  font-weight: bold;
}

/* 隐藏天气相关元素 */
.weather-icon-top {
  display: none !important;
}

.weather-panel {
  display: none !important;
}

/* Contact me 部分样式 */
.contact-me {
  margin-top: 20px;
  margin-bottom: 20px;
  padding: 15px;
  border: 2px solid #ff5252;
  border-radius: 8px;
  background-color: #ffe0e0;
  display: block !important;
  position: relative;
  z-index: 100;
}

.contact-me h3 {
  color: #d32f2f;
  margin-top: 0;
  margin-bottom: 10px;
  font-weight: bold;
}

.contact-link {
  display: flex;
  align-items: center;
  color: #333;
  text-decoration: none;
  padding: 10px;
  border-radius: 5px;
  transition: background-color 0.3s;
  background-color: white;
  border: 1px solid #ddd;
}

.contact-link:hover {
  background-color: #f5f5f5;
}

.contact-icon {
  width: 24px;
  height: 24px;
  margin-right: 10px;
} 