/* servisas.elmitra.lt — mobile-first */
:root {
  --brand: #23559E;
  --brand-dark: #1a4076;
  --accent: #6EDBB3;
  --err: #c0392b;
  --border: #cfd8e3;
  --bg: #f4f6f9;
  --text: #1c2733;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 16px;
  line-height: 1.5;
}
.site-header {
  background: #fff;
  border-bottom: 3px solid var(--brand);
  padding: 16px 0;
}
.header-inner {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 16px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.site-header .logo { height: 48px; width: auto; }
.site-header h1 { font-size: 1.25rem; margin: 0; color: var(--brand); text-align: right; }
main { max-width: 720px; margin: 0 auto; padding: 16px; }
.intro { color: #43566b; }
.alert { padding: 12px 16px; border-radius: 8px; margin: 16px 0; }
.alert-warning { background: #fdf3e3; border: 1px solid #e8c98b; }
.alert-error { background: #fdecea; border: 1px solid #e5a49d; color: var(--err); }
.alert-success { background: #e8f8f0; border: 1px solid #9adbbd; }

fieldset {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px;
  margin: 0 0 16px;
}
legend { font-weight: 700; color: var(--brand); padding: 0 6px; }
label { display: block; font-weight: 600; margin: 14px 0 4px; }
label.choice { font-weight: 400; margin: 6px 0; display: flex; gap: 10px; align-items: flex-start; }
label.choice input { margin-top: 3px; flex-shrink: 0; width: 18px; height: 18px; }
label.consent { font-weight: 600; }
.hint { font-size: 0.875rem; color: #5b6b7d; margin: 0 0 6px; font-weight: 400; }
.hint-inline { font-size: 0.85rem; color: #5b6b7d; font-weight: 400; }
.req { color: var(--err); }
input[type=text], input[type=tel], input[type=email], input[type=date], input[type=password], textarea {
  width: 100%;
  padding: 11px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font: inherit;
  background: #fff;
}
input:focus, textarea:focus { outline: 2px solid var(--brand); outline-offset: 0; border-color: var(--brand); }
.has-err input, input.has-err, textarea.has-err, div.has-err { border-color: var(--err); }
fieldset.has-err { border-color: var(--err); }
.err { color: var(--err); font-size: 0.875rem; margin: 4px 0 0; }
.conditional { display: none; margin-left: 8px; padding-left: 16px; border-left: 3px solid var(--accent); }
.conditional.visible { display: block; }
input[type=file] { width: 100%; padding: 10px 0; }
.file-list { list-style: none; padding: 0; margin: 6px 0 0; font-size: 0.875rem; color: #43566b; }
.file-list li {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 6px 10px; margin-top: 6px; background: var(--bg);
  border: 1px solid var(--border); border-radius: 6px;
}
.file-list li span { overflow-wrap: anywhere; }
.file-remove {
  flex-shrink: 0; background: #fff; border: 1px solid var(--err); color: var(--err);
  border-radius: 6px; padding: 4px 10px; font: inherit; font-size: 0.85rem; cursor: pointer;
}
.file-remove:hover { background: #fdecea; }
.hp { position: absolute; left: -9999px; top: -9999px; }

button[type=submit] {
  width: 100%;
  background: var(--brand);
  color: #fff;
  font: inherit;
  font-weight: 700;
  font-size: 1.1rem;
  border: 0;
  border-radius: 10px;
  padding: 15px;
  cursor: pointer;
}
button[type=submit]:hover { background: var(--brand-dark); }
button[type=submit]:disabled { background: #8fa6c8; cursor: wait; }

footer { text-align: center; font-size: 0.85rem; color: #5b6b7d; padding: 24px 16px; }
footer a { color: var(--brand); }

/* Ačiū puslapis */
.thanks { background: #fff; border: 1px solid var(--border); border-radius: 10px; padding: 24px; text-align: center; }
.thanks .regnr { font-size: 1.6rem; font-weight: 800; color: var(--brand); margin: 12px 0; }

/* Admin */
.admin-nav { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; margin: 0 0 16px;
  padding: 10px 14px; background: #fff; border: 1px solid var(--border); border-radius: 8px; }
.admin-nav a { color: var(--brand); font-weight: 600; text-decoration: none; }
.admin-nav a.active { text-decoration: underline; text-underline-offset: 4px; }
.admin-nav .admin-user { margin-left: auto; color: #5b6b7d; }
.btn { display: inline-block; background: var(--brand); color: #fff; padding: 10px 18px; border: 0;
  border-radius: 8px; text-decoration: none; font: inherit; font-weight: 600; cursor: pointer; }
.btn-secondary { background: #5b6b7d; }
.btn-small { padding: 5px 10px; font-size: 0.85rem; }
.btn-danger { background: var(--err); }
.badge { display: inline-block; padding: 2px 8px; border-radius: 10px; font-size: 0.8rem; font-weight: 700; white-space: nowrap; }
.badge-done { background: #e8f8f0; color: #1e8e5a; border: 1px solid #9adbbd; }
.badge-open { background: #fdf3e3; color: #8a5a00; border: 1px solid #e8c98b; }
.comments { list-style: none; padding: 0; margin: 0 0 16px; }
.comments li { background: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 10px 14px; margin-bottom: 8px; }
.comments .meta { font-size: 0.8rem; color: #5b6b7d; margin-bottom: 4px; }
.comments li.status { background: var(--bg); font-style: italic; }
.comments .body { white-space: pre-wrap; overflow-wrap: anywhere; }
code.pw { font-size: 1.1rem; background: #fff; padding: 2px 8px; border: 1px solid var(--border); border-radius: 4px; user-select: all; }

@media (min-width: 600px) {
  .site-header { padding: 20px 0; }
  .site-header h1 { font-size: 1.5rem; }
  main { padding: 24px 16px; }
  button[type=submit] { width: auto; padding: 15px 48px; }
}
