/* Lopi — tokens compartilhados (docs/design-system/tokens.md).
   O verde é a identidade; o laranja é a interface. */
:root {
	--green: #2e8b57;
	--green-dark: #256c46;
	--orange: #ff914d;
	--orange-dark: #cc753e;
	--ink: #1a1a1a;
	--ink-soft: #4d4d4d;
	--canvas: #f5f5f5;
	--surface: #ffffff;
	--line: #e4e4df;
}

* {
	box-sizing: border-box;
}

body {
	margin: 0;
	background: var(--canvas);
	color: var(--ink);
	font-family: "Nunito", "Avenir Next", "Segoe UI", system-ui, sans-serif;
	font-size: 17px;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
}

.wrap {
	max-width: 720px;
	margin: 0 auto;
	padding: 32px 22px 72px;
}

header.site {
	display: flex;
	align-items: center;
	gap: 14px;
	padding-bottom: 22px;
	border-bottom: 1px solid var(--line);
	flex-wrap: wrap;
}
/* The wordmark from store/brand/logo.svg (Nunito Black, paw as the i's dot). */
header.site a.brand {
	display: block;
	line-height: 0;
}
header.site a.brand img {
	display: block;
	height: 32px;
	width: auto;
}
header.site nav {
	margin-left: auto;
	display: flex;
	gap: 18px;
}
header.site nav a {
	color: var(--ink-soft);
	text-decoration: none;
	font-size: 15px;
	font-weight: 600;
}
header.site nav a:hover,
header.site nav a:focus-visible {
	color: var(--orange-dark);
}

h1 {
	font-size: clamp(30px, 5.5vw, 44px);
	line-height: 1.1;
	letter-spacing: -0.025em;
	font-weight: 800;
	margin: 34px 0 14px;
	text-wrap: balance;
}
h2 {
	font-size: 21px;
	font-weight: 800;
	letter-spacing: -0.015em;
	margin: 38px 0 10px;
	color: var(--green-dark);
}
h3 {
	font-size: 17px;
	font-weight: 700;
	margin: 22px 0 6px;
}
p {
	margin: 0 0 14px;
}
a {
	color: var(--orange-dark);
}

.lead {
	font-size: 19px;
	color: var(--ink-soft);
	margin-bottom: 26px;
}

ul {
	margin: 0 0 14px;
	padding-left: 22px;
}
li {
	margin-bottom: 7px;
}

.card {
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: 12px;
	padding: 20px 22px;
	margin: 22px 0;
}
.card h3 {
	margin-top: 0;
}

.features {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
	gap: 14px;
	margin: 26px 0;
}
.features div {
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: 12px;
	padding: 17px 19px;
}
.features strong {
	display: block;
	color: var(--green-dark);
	margin-bottom: 4px;
}

.notice {
	border-left: 4px solid var(--orange);
	background: var(--surface);
	border-radius: 0 10px 10px 0;
	padding: 15px 18px;
	margin: 24px 0;
}

table {
	border-collapse: collapse;
	width: 100%;
	margin: 14px 0 20px;
	font-size: 15.5px;
}
th,
td {
	text-align: left;
	padding: 9px 12px;
	border-bottom: 1px solid var(--line);
	vertical-align: top;
}
th {
	font-weight: 700;
	color: var(--green-dark);
}
.table-scroll {
	overflow-x: auto;
}

.updated {
	font-size: 15px;
	color: var(--ink-soft);
}

footer.site {
	margin-top: 54px;
	padding-top: 20px;
	border-top: 1px solid var(--line);
	font-size: 14.5px;
	color: var(--ink-soft);
	display: flex;
	gap: 18px;
	flex-wrap: wrap;
}
footer.site a {
	color: var(--ink-soft);
}

:focus-visible {
	outline: 2px solid var(--orange);
	outline-offset: 2px;
}

/* Pet page of the lost-pet tag (/p/<token>). Mobile first: it is opened from a
   phone camera, often on a street, often with one hand. The ways to reach the
   family sit in a bar at the bottom, within thumb reach. */
.pet-wrap {
	padding-top: 20px;
}
.pet-page {
	display: flex;
	flex-direction: column;
	gap: 16px;
	padding-top: 14px;
}
.pet-page.has-actions {
	padding-bottom: 96px;
}
.pet-hero {
	background: var(--green);
	color: var(--surface);
	border-radius: 22px;
	padding: 26px 20px 24px;
	text-align: center;
}
.pet-hero h1 {
	color: var(--surface);
	margin: 14px 0 6px;
}
.pet-hero .lead {
	color: var(--surface);
	opacity: 0.88;
	margin: 0;
}
.pet-photo {
	display: block;
	width: 148px;
	height: 148px;
	margin: 0 auto;
	border-radius: 50%;
	object-fit: cover;
	border: 4px solid var(--green-dark);
}
.pet-photo-empty circle {
	fill: var(--line);
}
.pet-photo-empty g {
	fill: var(--surface);
}
.pet-note {
	margin: 0;
	background: var(--surface);
	border: 1px solid var(--line);
	border-left: 4px solid var(--orange);
	border-radius: 12px;
	padding: 12px 16px;
	white-space: pre-line;
	overflow-wrap: anywhere;
}
.pet-page .notice {
	margin: 0;
}
.pet-page .notice.ok {
	border-left-color: var(--green);
}
.pet-phone {
	margin: 0;
}

.pet-location {
	display: grid;
	grid-template-columns: auto 1fr;
	gap: 6px 12px;
	align-items: center;
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: 16px;
	padding: 14px 16px;
}
.pet-location[hidden] {
	display: none;
}
.pet-location-icon {
	color: var(--green-dark);
	line-height: 0;
}
.pet-location-icon svg {
	width: 26px;
	height: 26px;
	fill: none;
	stroke: currentColor;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
}
.pet-location p {
	margin: 0;
	font-size: 15.5px;
}
.pet-location .button,
.pet-location .fine {
	grid-column: 1 / -1;
}
.pet-location .button {
	margin: 6px 0 0;
}
.pet-location .fine:empty {
	display: none;
}

.button {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: 100%;
	min-height: 52px;
	margin: 0;
	padding: 12px 18px;
	border: 2px solid var(--orange);
	border-radius: 12px;
	background: var(--surface);
	color: var(--orange-dark);
	font: inherit;
	font-weight: 800;
	text-align: center;
	text-decoration: none;
	cursor: pointer;
}
.button.primary {
	background: var(--orange);
	color: var(--surface);
}
.button.green {
	background: var(--green);
	border-color: var(--green);
	color: var(--surface);
}
.button:disabled {
	opacity: 0.6;
	cursor: default;
}
.button svg {
	width: 20px;
	height: 20px;
	flex: none;
	fill: none;
	stroke: currentColor;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
}
.fine {
	font-size: 14.5px;
	color: var(--ink-soft);
	margin: 6px 0 0;
}

.pet-actions {
	position: fixed;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 10;
	display: flex;
	gap: 8px;
	max-width: 720px;
	margin: 0 auto;
	padding: 10px 14px calc(12px + env(safe-area-inset-bottom, 0px));
	background: var(--surface);
	border-top: 1px solid var(--line);
	box-shadow: 0 -10px 24px -18px rgba(0, 0, 0, 0.35);
}
.pet-actions .button {
	flex: 1;
	min-width: 0;
	flex-direction: column;
	gap: 2px;
	min-height: 58px;
	padding: 6px 8px;
	font-size: 15px;
}

.pet-message {
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: 16px;
	padding: 16px;
}
.pet-message-head {
	display: flex;
	align-items: center;
	gap: 12px;
}
.pet-message-head h2 {
	margin: 0;
	flex: 1;
}
.sheet-close {
	display: none;
}
.pet-message label {
	display: block;
	font-weight: 700;
	margin: 12px 0 6px;
}
.pet-message textarea,
.pet-message input {
	display: block;
	width: 100%;
	padding: 12px 14px;
	border: 1px solid var(--line);
	border-radius: 10px;
	background: var(--surface);
	color: var(--ink);
	font: inherit;
}
.pet-message .button {
	margin-top: 16px;
}
.pet-message .fine:empty {
	display: none;
}

/* With the script, the message form is a sheet opened from the bar. */
.pet-js .pet-message {
	display: none;
}
.pet-js .pet-message.open {
	display: block;
	position: fixed;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 30;
	max-width: 720px;
	max-height: 88vh;
	margin: 0 auto;
	overflow-y: auto;
	border-radius: 22px 22px 0 0;
	padding: 18px 18px calc(18px + env(safe-area-inset-bottom, 0px));
	box-shadow: 0 -16px 40px -12px rgba(0, 0, 0, 0.35);
}
.pet-js .sheet-close {
	display: inline-block;
	border: 0;
	background: none;
	color: var(--orange-dark);
	font: inherit;
	font-weight: 800;
	padding: 8px 4px;
	cursor: pointer;
}
.pet-scrim {
	position: fixed;
	inset: 0;
	z-index: 20;
	background: rgba(0, 0, 0, 0.38);
}
@media (prefers-reduced-motion: no-preference) {
	.pet-js .pet-message.open {
		animation: pet-sheet 0.22s ease-out;
	}
	@keyframes pet-sheet {
		from {
			transform: translateY(24px);
			opacity: 0.6;
		}
		to {
			transform: none;
			opacity: 1;
		}
	}
}

.pet-footer {
	margin-top: 40px;
	font-size: 14.5px;
	color: var(--ink-soft);
	text-align: center;
}
.pet-footer a {
	color: var(--ink-soft);
}
