:root {
  --bg: #f6f4ef;
  --text: #1a1f2b;
  --muted: #586174;
  --card: #ffffff;
  --line: #dde2ee;
  --accent: #1248c6;
  --accent2: #0f3da7;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Inter", "Segoe UI", sans-serif;
  color: var(--text);
  background: radial-gradient(circle at 0 0, #e8edf8, var(--bg) 50%);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 20px;
  background: rgba(255, 255, 255, 0.9);
  border-bottom: 1px solid var(--line);
}

.topbar nav {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.topbar a {
  color: var(--text);
  text-decoration: none;
}

.brand {
  font-weight: 800;
}

.container {
  max-width: 1160px;
  margin: 20px auto;
  padding: 0 16px;
}

.hero,
.panel,
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
}

.hero,
.panel {
  padding: 20px;
  margin-bottom: 14px;
}

.subtitle,
.muted {
  color: var(--muted);
}

.meta {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.progress {
  margin-top: 12px;
  height: 10px;
  border-radius: 999px;
  background: #e7ebf5;
}

.progress span {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), #4b7cff);
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.grid.two {
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.card {
  padding: 14px;
}

.price {
  font-size: 22px;
  font-weight: 800;
  margin: 8px 0;
}

ul {
  padding-left: 18px;
}

.btn {
  border: 0;
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  padding: 10px 14px;
  cursor: pointer;
  text-decoration: none;
}

.btn:hover {
  background: var(--accent2);
}

.btn.small {
  padding: 8px 10px;
  font-size: 12px;
}

.btn.ghost {
  background: #f1f5ff;
  color: #1f305a;
}

.box {
  display: block;
  width: 100%;
  margin-bottom: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 9px;
  background: #fff;
}

.markdown {
  line-height: 1.55;
}

.compose-wrap {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 12px;
}

.compose-main textarea {
  width: 100%;
  min-height: 180px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px;
  font-family: inherit;
}

.ai-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ai-actions button {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 10px;
  background: #fff;
  cursor: pointer;
}

@media (max-width: 900px) {
  .compose-wrap {
    grid-template-columns: 1fr;
  }
}
