:root {
  --bg: #f6f7f8;
  --card: #ffffff;
  --text: #151515;
  --muted: #666666;
  --light: #888888;
  --border: #eeeeee;
  --primary: #101010;
  --primary-text: #ffffff;
  --secondary: #ffffff;
  --shadow: 0 12px 30px rgba(0, 0, 0, 0.06);
  --radius-lg: 22px;
  --radius-md: 16px;
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue", Arial, sans-serif;
}

body {
  padding: env(safe-area-inset-top) 0 env(safe-area-inset-bottom);
}

button,
textarea {
  font-family: inherit;
}

.page-shell {
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
  padding: 18px 16px 28px;
}

.hero-card,
.activity-card,
.copy-card,
.tips-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.hero-card {
  padding: 24px 20px 22px;
  background: linear-gradient(180deg, #ffffff 0%, #fafafa 100%);
}

.brand-line {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  background: #f0f0f0;
  color: #333333;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
}

h1 {
  margin: 18px 0 8px;
  font-size: 28px;
  line-height: 1.18;
  letter-spacing: -0.4px;
}

.hero-card p,
.activity-card p,
.tips-card p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
}

.activity-card,
.copy-card,
.tips-card {
  margin-top: 14px;
  padding: 18px;
}

.section-label {
  display: inline-block;
  color: var(--light);
  font-size: 13px;
  line-height: 1.4;
}

.activity-card h2 {
  margin: 8px 0 8px;
  font-size: 20px;
  line-height: 1.35;
}

.copy-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.copy-meta {
  flex-shrink: 0;
  color: var(--light);
  font-size: 12px;
}

.copy-content {
  min-height: 218px;
  padding: 18px;
  border-radius: var(--radius-md);
  background: #fafafa;
  border: 1px dashed #dddddd;
  color: var(--text);
  font-size: 18px;
  line-height: 1.78;
  white-space: pre-wrap;
  word-break: break-word;
  user-select: text;
  -webkit-user-select: text;
}

.copy-content:focus {
  outline: 2px solid rgba(0, 0, 0, 0.12);
  outline-offset: 3px;
}

.action-area {
  display: grid;
  grid-template-columns: 1fr 1.18fr;
  gap: 12px;
  margin-top: 14px;
  position: sticky;
  bottom: 12px;
  z-index: 2;
}

.btn {
  width: 100%;
  min-height: 52px;
  border: 0;
  border-radius: 16px;
  font-size: 17px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.08);
}

.btn:active {
  transform: scale(0.985);
}

.btn-primary {
  background: var(--primary);
  color: var(--primary-text);
}

.btn-secondary {
  background: var(--secondary);
  color: var(--text);
  border: 1px solid var(--border);
}

.tips-card {
  padding: 14px 16px;
  box-shadow: none;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(86px + env(safe-area-inset-bottom));
  transform: translateX(-50%) translateY(16px);
  max-width: calc(100vw - 44px);
  padding: 11px 14px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.82);
  color: #ffffff;
  font-size: 14px;
  line-height: 1.4;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease;
  z-index: 10;
  text-align: center;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

@media (min-width: 768px) {
  .page-shell {
    padding-top: 34px;
  }

  .action-area {
    position: static;
  }
}
