:root {
  --bg: #f6f4ef;
  --panel: #ffffff;
  --text: #1f1f1f;
  --muted: #6b6b6b;
  --accent: #0b3d2e;
  --accent-2: #c8732f;
  --border: #e2ded5;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: "Georgia", "Times New Roman", serif;
  color: var(--text);
  background: radial-gradient(circle at top left, #fff7eb, var(--bg));
}

header {
  padding: 18px 24px;
  background: var(--panel);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

header h1 {
  margin: 0;
  font-size: 20px;
  letter-spacing: 0.4px;
}

nav a {
  margin-right: 14px;
  text-decoration: none;
  color: var(--text);
  font-weight: 600;
}

nav a.active {
  color: var(--accent);
}

main {
  padding: 24px;
  max-width: 1100px;
  margin: 0 auto;
}

.panel {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 18px;
  margin-bottom: 18px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.04);
}

.panel h2 {
  margin-top: 0;
}

.grid {
  display: grid;
  gap: 16px;
}

.grid-2 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }

label { display: block; font-weight: 600; margin-bottom: 6px; }
input, textarea, select {
  width: 100%;
  padding: 10px;
  border-radius: 6px;
  border: 1px solid var(--border);
  font-family: inherit;
  background: #fff;
}

textarea { min-height: 110px; }

button {
  background: var(--accent);
  color: #fff;
  border: none;
  padding: 10px 14px;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 600;
}

button.secondary {
  background: var(--accent-2);
}

button.ghost {
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--accent);
}

.inline {
  display: inline-flex;
  gap: 10px;
  align-items: center;
}

small { color: var(--muted); }

.table {
  width: 100%;
  border-collapse: collapse;
}

.table th, .table td {
  border: 1px solid var(--border);
  padding: 8px;
  text-align: left;
}

.notice { padding: 10px; background: #fff5e6; border-radius: 6px; border: 1px solid #f0d7b2; }

.footer-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.codebox {
  font-family: "Courier New", monospace;
  white-space: pre-wrap;
  background: #f8f5f0;
  border: 1px dashed var(--border);
  padding: 12px;
  border-radius: 6px;
  min-height: 120px;
}

iframe.preview {
  width: 100%;
  min-height: 300px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
}

@media (max-width: 720px) {
  header { flex-direction: column; align-items: flex-start; gap: 10px; }
  nav { display: flex; flex-wrap: wrap; }
}
