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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  min-height: 100vh;
  -webkit-text-size-adjust: 100%;
}

.container {
  width: 100%;
  max-width: 750px;
  margin: 0 auto;
  padding: 12px;
  min-height: 100vh;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.header {
  text-align: center;
  margin-bottom: 10px;
}

.title {
  font-size: 26px;
  font-weight: bold;
  color: #fff;
  margin-bottom: 4px;
}

.subtitle {
  font-size: 14px;
  color: rgba(255,255,255,0.8);
}

.section {
  background: #fff;
  border-radius: 10px;
  padding: 12px;
  margin-bottom: 6px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

.section-title {
  font-size: 17px;
  font-weight: bold;
  color: #333;
  margin-bottom: 8px;
}

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

.section-header .section-title {
  margin-bottom: 0;
}

.keyword-input {
  width: 100%;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 17px;
}

.keyword-input:focus {
  outline: none;
  border-color: #667eea;
}

.style-buttons {
  display: flex;
  gap: 8px;
  margin-bottom: 8px;
}

.style-btn {
  flex: 1;
  padding: 12px 6px;
  font-size: 15px;
  font-weight: bold;
  border-radius: 8px;
  border: 2px solid #e0e0e0;
  background: #fff;
  color: #333;
  cursor: pointer;
  transition: all 0.3s;
}

.style-btn.selected.douyin,
.style-btn[data-style="douyin"].active {
  background: linear-gradient(135deg, #fe2c55, #25f4ee);
  border-color: #fe2c55;
  color: #fff;
}

.style-btn.selected.video,
.style-btn[data-style="video"].active {
  background: linear-gradient(135deg, #667eea, #764ba2);
  border-color: #667eea;
  color: #fff;
}

.style-btn.selected.red,
.style-btn[data-style="xiaohongshu"].active {
  background: linear-gradient(135deg, #ff6b6b, #ff4757);
  border-color: #ff4757;
  color: #fff;
}


.source-select {
  padding: 6px 10px;
  font-size: 14px;
  border: 1px solid #e0e0e0;
  border-radius: 6px;
  background: #f5f5f5;
  color: #667eea;
  cursor: pointer;
}

.hot-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.hot-item {
  width: calc(33.33% - 4px);
  background: #f5f5f5;
  border-radius: 6px;
  padding: 10px 4px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.3s;
}

.hot-item.selected {
  border-color: #667eea;
  background: #e8f0ff;
}

.hot-item-inner {
  min-height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hot-title {
  font-size: 14px;
  color: #333;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  line-height: 1.3;
}

.hot-loading {
  width: 100%;
  text-align: center;
  padding: 14px;
  color: #666;
  font-size: 14px;
}

.picker-select {
  width: 100%;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 17px;
  color: #333;
  background: #fff;
  cursor: pointer;
}

.picker-select.placeholder {
  color: #999;
}

.action-section {
  margin-top: 10px;
}

.generate-btn {
  width: 100%;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: #fff;
  font-size: 18px;
  padding: 15px;
  border-radius: 10px;
  border: none;
  cursor: pointer;
}

.generate-btn:disabled {
  background: #ccc;
  cursor: not-allowed;
}

.generate-btn.loading {
  opacity: 0.7;
}

/* Result Section */
.result-section {
  background: #fff;
  border-radius: 10px;
  padding: 12px;
  margin-bottom: 6px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

.result-title {
  font-size: 17px;
  font-weight: bold;
  color: #333;
  margin-bottom: 10px;
  line-height: 1.4;
}

.result-body {
  font-size: 15px;
  color: #444;
  line-height: 1.6;
  margin-bottom: 10px;
  white-space: pre-wrap;
}

.result-tags {
  font-size: 14px;
  color: #667eea;
  margin-bottom: 10px;
}

.result-tags span {
  display: inline-block;
  margin-right: 12px;
}

.result-section .topic {
  padding-bottom: 8px;
  border-bottom: 1px solid #eee;
  margin-bottom: 8px;
}

.topic-label {
  font-size: 15px;
  color: #666;
}

.topic-value {
  font-size: 17px;
  color: #333;
  font-weight: bold;
}

.content-section {
  margin-bottom: 10px;
}

.content {
  display: block;
  font-size: 16px;
  color: #444;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-all;
}

.actions {
  display: flex;
  gap: 10px;
}

.action-btn {
  flex: 1;
  padding: 13px;
  border-radius: 8px;
  font-size: 16px;
  border: none;
  cursor: pointer;
}

.copy-btn {
  background: #f0f0f0;
  color: #333;
}

.disclaimer {
  text-align: center;
  font-size: 12px;
  color: rgba(255,255,255,0.6);
  padding: 10px 0;
}

/* Floating Customer Service */
.float-customer-service {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 999;
}

.float-customer-toggle {
  width: 48px;
  height: 48px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 2px 12px rgba(0,0,0,0.15);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s;
}

.float-customer-toggle:hover {
  transform: scale(1.1);
}

.float-customer-toggle img {
  width: 24px;
  height: 24px;
}

.float-customer-popup {
  position: absolute;
  bottom: 60px;
  right: 0;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
  padding: 16px;
  min-width: 200px;
  max-width: 280px;
}

.float-customer-close {
  position: absolute;
  top: 4px;
  right: 10px;
  font-size: 24px;
  color: #999;
  cursor: pointer;
  line-height: 1;
}

.float-customer-close:hover {
  color: #333;
}

.float-customer-content img {
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: 8px;
}

@media screen and (max-width: 768px) {
  .float-customer-service {
    bottom: 15px;
    right: 15px;
  }

  .float-customer-toggle {
    width: 44px;
    height: 44px;
  }

  .float-customer-popup {
    min-width: 180px;
    max-width: 250px;
  }
}

/* Toast */
.toast {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(0,0,0,0.7);
  color: #fff;
  padding: 14px 28px;
  border-radius: 8px;
  font-size: 15px;
  z-index: 1000;
  display: none;
  max-width: 80%;
  text-align: center;
}

.toast.show {
  display: block;
}

/* Tablets */
@media screen and (min-width: 768px) {
  .container {
    padding: 20px;
  }

  .header {
    margin-bottom: 14px;
  }

  .title {
    font-size: 30px;
  }

  .subtitle {
    font-size: 15px;
  }

  .section {
    border-radius: 14px;
    padding: 16px;
    margin-bottom: 10px;
  }

  .section-title {
    font-size: 19px;
    margin-bottom: 12px;
  }

  .section-header {
    margin-bottom: 12px;
  }

  .keyword-input {
    border-radius: 10px;
    padding: 14px 16px;
    font-size: 18px;
  }

  .style-buttons {
    gap: 12px;
    margin-bottom: 12px;
  }

  .style-btn {
    padding: 14px;
    font-size: 16px;
    border-radius: 10px;
  }

  .source-select {
    padding: 8px 12px;
    font-size: 15px;
    border-radius: 8px;
  }

  .hot-list {
    gap: 10px;
  }

  .hot-item {
    border-radius: 8px;
    padding: 12px;
    width: calc(33.33% - 7px);
  }

  .hot-item-inner {
    min-height: 44px;
  }

  .hot-title {
    font-size: 15px;
  }

  .hot-loading {
    padding: 20px;
    font-size: 15px;
  }

  .picker-select {
    border-radius: 10px;
    padding: 14px 16px;
    font-size: 18px;
  }

  .action-section {
    margin-top: 14px;
  }

  .generate-btn {
    font-size: 19px;
    padding: 16px;
    border-radius: 12px;
  }

  .result-section {
    border-radius: 14px;
    padding: 16px;
    margin-bottom: 10px;
  }

  .result-title {
    font-size: 19px;
    margin-bottom: 12px;
  }

  .result-body {
    font-size: 16px;
    margin-bottom: 12px;
  }

  .result-tags {
    font-size: 15px;
    margin-bottom: 12px;
  }

  .actions {
    gap: 12px;
  }

  .action-btn {
    padding: 14px;
    font-size: 16px;
    border-radius: 10px;
  }

  .disclaimer {
    font-size: 13px;
    padding: 14px 0;
  }

  .toast {
    padding: 16px 32px;
    font-size: 16px;
    border-radius: 10px;
  }
}
