/* PataTag — mobile-first, no external fonts, no inline styles (CSP style-src 'self'). */
:root {
  --bg: #fffaf3; --card: #ffffff; --ink: #1f2937; --muted: #6b7280;
  --brand: #f59e0b; --brand-dark: #b45309; --ok: #047857; --err: #b91c1c; --warn: #92400e;
  --line: #f1e4cf; --radius: 14px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink);
  font: 16px/1.55 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; }
a { color: var(--brand-dark); }
img { max-width: 100%; height: auto; }
h1 { font-size: 1.7rem; line-height: 1.2; margin: .2em 0 .5em; }
h2 { font-size: 1.3rem; margin: 1.2em 0 .5em; }
h3 { font-size: 1.05rem; margin: .2em 0; }
code { background: #fef3c7; padding: 1px 5px; border-radius: 4px; font-size: .92em; word-break: break-all; }

.container { max-width: 760px; margin: 0 auto; padding: 16px; }
.container.wide { max-width: 1100px; }
.site-header { display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 12px 16px; background: var(--card); border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 1.15rem;
  color: var(--ink); text-decoration: none; }
.lang a { padding: 6px 10px; border-radius: 999px; text-decoration: none; font-weight: 600; color: var(--muted); }
.lang a[aria-current="true"] { background: var(--brand); color: #fff; }
.site-footer { text-align: center; padding: 24px 16px 40px; color: var(--muted); font-size: .9rem; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 8px 16px; justify-content: center; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px; margin: 16px 0; box-shadow: 0 1px 2px rgba(0,0,0,.03); }
.card.center, .center { text-align: center; }
.card.narrow { max-width: 420px; margin-left: auto; margin-right: auto; }
.muted { color: var(--muted); }
.small { font-size: .88rem; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

.btn { display: inline-block; border: 2px solid var(--brand-dark); background: #fff; color: var(--brand-dark);
  padding: 12px 20px; border-radius: 999px; font-weight: 700; font-size: 1rem; text-decoration: none;
  cursor: pointer; text-align: center; }
.btn-primary { background: var(--brand); border-color: var(--brand); color: #111; }
.btn:hover { filter: brightness(.96); }
.btn.small { padding: 6px 12px; font-size: .88rem; }
.btn.danger { border-color: var(--err); color: var(--err); }
.linklike { background: none; border: 0; color: var(--brand-dark); text-decoration: underline; cursor: pointer; font: inherit; padding: 0; }

.hero { display: grid; gap: 16px; align-items: center; padding: 8px 0 16px; }
.hero h1 { font-size: 2.2rem; }
.lead { font-size: 1.1rem; }
.price { font-size: 1.3rem; font-weight: 800; }
.hero-img { text-align: center; }
.steps { list-style: none; padding: 0; display: grid; gap: 12px; }
.steps li { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.checks { padding-left: 1.2em; }
.checks li { margin: 4px 0; }

.form label { display: block; font-weight: 600; margin: 12px 0 4px; }
.form input, .form select, .form textarea { display: block; width: 100%; margin-top: 4px; padding: 12px;
  font: inherit; border: 1.5px solid #d6c7ad; border-radius: 10px; background: #fff; }
.form input:focus, .form select:focus, .form textarea:focus { outline: 3px solid #fcd34d; border-color: var(--brand-dark); }
.form [aria-invalid="true"] { border-color: var(--err); }
.form button { margin-top: 16px; }
.form fieldset { border: 1px solid var(--line); border-radius: 12px; padding: 8px 14px 14px; margin: 16px 0; }
.form legend { font-weight: 800; padding: 0 6px; }
.form .check { display: flex; gap: 8px; align-items: center; font-weight: 500; }
.form .check input { width: auto; margin: 0; }
.form.inline { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: flex-end; }
.form.inline label { flex: 1 1 180px; margin: 0; }
.form.inline button { margin: 0; }
.hint { color: var(--muted); font-size: .88rem; margin: 4px 0; }
.field-error { color: var(--err); font-size: .9rem; margin: 4px 0 0; font-weight: 600; }
.owner-row { border-top: 1px dashed var(--line); padding-top: 8px; margin-top: 10px; }
.owner-label { font-weight: 700; color: var(--brand-dark); }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.notice { padding: 10px 14px; border-radius: 10px; background: #fef3c7; border: 1px solid #fcd34d; }
.notice.success { background: #d1fae5; border-color: #6ee7b7; color: var(--ok); }
.notice.error { background: #fee2e2; border-color: #fca5a5; color: var(--err); }
.notice.warn { background: #fff7ed; border-color: #fdba74; color: var(--warn); font-size: .9rem; }
.draft-banner { background: #fee2e2; border: 2px dashed var(--err); color: var(--err); padding: 10px 14px;
  border-radius: 10px; font-weight: 700; }

.buy-grid { display: flex; gap: 16px; align-items: center; }
.facts { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; margin: 12px 0; }
.facts dt { font-weight: 700; color: var(--muted); }
.facts dd { margin: 0; }
.stock { font-weight: 800; color: var(--ok); grid-column: 1 / -1; }
.stock.out { color: var(--err); }

.profile { text-align: center; }
.pet-photo img { border-radius: 50%; width: 180px; height: 180px; object-fit: cover; border: 4px solid var(--brand); }
.pet-photo img.placeholder { border: 0; border-radius: 0; width: 120px; height: 120px; }
.found { font-size: 1.1rem; }
.owners { list-style: none; padding: 0; margin: 12px 0; display: grid; gap: 10px; }
.owner { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; align-items: center; text-align: left;
  background: #fffbeb; border: 1px solid #fde68a; border-radius: 12px; padding: 12px 14px; }
.owner-name { font-weight: 700; font-size: 1.1rem; }
.owner-phone { grid-column: 1; font-size: 1.25rem; font-weight: 800; color: var(--ink); text-decoration: none; letter-spacing: .02em; }
.btn-call { grid-column: 2; grid-row: 1 / span 2; background: var(--ok); border-color: var(--ok); color: #fff; }
.profile .facts { text-align: left; max-width: 420px; margin: 16px auto; }
.legal h2 { font-size: 1.1rem; }
.legal blockquote { border-left: 4px solid var(--line); margin: 0; padding: 8px 14px; background: #fffbeb; }

/* admin */
.admin-nav { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; }
.admin-nav a[aria-current="page"] { font-weight: 800; }
.inline-form { display: inline-flex; gap: 6px; align-items: center; flex-wrap: wrap; margin: 0; }
.inline-form input { padding: 6px 8px; border: 1px solid #d6c7ad; border-radius: 8px; font: inherit; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 12px; }
.filters a { padding: 4px 10px; border-radius: 999px; background: #fff; border: 1px solid var(--line); text-decoration: none; }
.filters a[aria-current="page"] { background: var(--brand); color: #111; }
.order-head { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.order-body { display: grid; gap: 8px; }
.order-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 8px; }
.order.status-oversold { border: 2px solid var(--err); }
.badge { padding: 2px 8px; border-radius: 999px; font-size: .8rem; font-weight: 700; background: #e5e7eb; }
.badge-paid, .badge-new { background: #fde68a; }
.badge-oversold { background: var(--err); color: #fff; }
.badge-fulfilled, .badge-contacted { background: #bfdbfe; }
.badge-shipped, .badge-converted { background: #a7f3d0; }
.badge-cancelled { background: #e5e7eb; color: var(--muted); }
.note { white-space: pre-line; background: #fef3c7; padding: 6px 8px; border-radius: 8px; }
.pre { white-space: pre-line; }
details.danger summary { cursor: pointer; color: var(--err); }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px; font-size: .85rem; color: var(--muted); }
.stat span { display: block; font-size: 1.6rem; font-weight: 800; color: var(--ink); }
.table { width: 100%; border-collapse: collapse; background: #fff; margin: 12px 0; font-size: .92rem; }
.table th, .table td { border-bottom: 1px solid var(--line); padding: 8px; text-align: left; }
address { font-style: normal; }

@media (min-width: 720px) {
  .hero { grid-template-columns: 1.2fr 1fr; padding: 24px 0; }
  .hero h1 { font-size: 2.8rem; }
  .steps { grid-template-columns: repeat(3, 1fr); }
  .order-body { grid-template-columns: 1fr 1fr; }
}
