:root {
  --bg: #f4f7fb;
  --panel: #ffffff;
  --text: #0d1626;
  --muted: #54627a;
  --line: #d7deeb;
  --accent: #0b64f4;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  color: var(--text);
  background: radial-gradient(circle at 20% 10%, #eaf1ff 0%, #f4f7fb 45%, #eef2f8 100%);
}

.layout {
  width: min(1100px, 94vw);
  margin: 20px auto 28px;
  display: grid;
  gap: 14px;
}

.header h1 {
  margin: 0 0 6px;
  font-size: 1.7rem;
}

.header p {
  margin: 0;
  color: var(--muted);
}

.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px;
  box-shadow: 0 6px 18px rgba(21, 35, 64, 0.06);
}

.panel h2 {
  margin: 0 0 10px;
  font-size: 1.05rem;
}

label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  margin-bottom: 6px;
}

input,
textarea,
select,
button {
  width: 100%;
  font: inherit;
}

input,
textarea,
select {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 9px 11px;
  background: #fcfdff;
  margin-bottom: 12px;
}

textarea {
  resize: vertical;
}

pre {
  margin: 0;
  background: #0f1525;
  color: #deebff;
  border-radius: 10px;
  padding: 10px;
  min-height: 100px;
  overflow: auto;
  font-size: 0.85rem;
}

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

.image-gallery .tile {
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
}

.image-gallery img {
  width: 100%;
  height: auto;
  display: block;
}

.image-gallery .meta {
  padding: 8px 10px;
  font-size: 0.82rem;
  color: var(--muted);
  border-top: 1px solid var(--line);
  background: #fcfdff;
  word-break: break-word;
}

.row {
  display: grid;
  gap: 10px;
}

.two-cols {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.actions {
  margin-top: 6px;
}

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

button:hover {
  filter: brightness(1.03);
}

.hint {
  margin-top: -6px;
  color: var(--muted);
  font-size: 0.84rem;
}

.hidden {
  display: none;
}

@media (max-width: 760px) {
  .two-cols {
    grid-template-columns: 1fr;
  }
}
