:root {
  --bg: var(--tg-theme-bg-color, #ffffff);
  --text: var(--tg-theme-text-color, #1c1c1e);
  --hint: var(--tg-theme-hint-color, #8e8e93);
  --link: var(--tg-theme-link-color, #2481cc);
  --button: var(--tg-theme-button-color, #2481cc);
  --button-text: var(--tg-theme-button-text-color, #ffffff);
  --card-bg: var(--tg-theme-secondary-bg-color, #f2f2f7);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.app-header {
  padding: 16px;
  position: sticky;
  top: 0;
  background: var(--bg);
  z-index: 1;
}

.app-header h1 {
  margin: 0;
  font-size: 20px;
}

.deal-list {
  padding: 0 12px 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.status {
  text-align: center;
  color: var(--hint);
  padding: 40px 0;
}

.deal-card {
  display: flex;
  gap: 12px;
  background: var(--card-bg);
  border-radius: 12px;
  padding: 10px;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}

.deal-thumb {
  width: 72px;
  height: 72px;
  border-radius: 8px;
  object-fit: cover;
  background: var(--bg);
  flex-shrink: 0;
}

.deal-info {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.deal-title {
  font-size: 14px;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.deal-tags {
  font-size: 11px;
  color: var(--hint);
}

.deal-price-row {
  display: flex;
  align-items: baseline;
  gap: 6px;
  font-size: 14px;
  font-weight: 700;
  color: var(--link);
}

.deal-discount {
  font-size: 11px;
  font-weight: 700;
  color: #ff3b30;
  background: rgba(255, 59, 48, 0.12);
  border-radius: 6px;
  padding: 1px 5px;
}

.deal-meta {
  font-size: 11px;
  color: var(--hint);
}
