/* ===========================================================
   Dr. João Pedro Paulino Ruas — main.css
   Mobile-first. Cores centralizadas em variáveis no :root.
   =========================================================== */

:root {
	--color-primary: #0d4f4a;      /* verde-petróleo institucional */
	--color-primary-dark: #083a36;
	--color-accent: #c9a15a;        /* dourado sutil de destaque */
	--color-bg: #ffffff;
	--color-bg-alt: #f4f7f6;
	--color-text: #1c2422;
	--color-text-muted: #566462;
	--color-border: #e1e8e6;
	--color-whatsapp: #25d366;

	--font-base: 'Segoe UI', system-ui, -apple-system, sans-serif;
	--font-brand: 'Playfair Display', Georgia, 'Times New Roman', serif;
	--container-width: 1140px;
	--radius: 10px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
	margin: 0;
	font-family: var(--font-base);
	color: var(--color-text);
	background: var(--color-bg);
	line-height: 1.6;
	font-size: 16px;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--color-primary); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3 { line-height: 1.25; margin: 0 0 1rem; color: var(--color-primary-dark); }
h1 { font-size: 1.75rem; }
h2 { font-size: 1.4rem; }
h3 { font-size: 1.1rem; }
p { margin: 0 0 1rem; }
ul { padding-left: 1.2rem; }

.sr-only {
	position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
	overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

.container {
	width: 100%;
	max-width: var(--container-width);
	margin: 0 auto;
	padding: 0 1.25rem;
}

.section { padding: 2.75rem 0; }
.section--alt { background: var(--color-bg-alt); }
.section__title { margin-bottom: 1.25rem; }
.section__narrow { max-width: 760px; margin-left: auto; margin-right: auto; }

.section__split {
	display: grid; grid-template-columns: 1fr; gap: 1.75rem; align-items: center;
}
.section__split--reverse .section__split-media { order: -1; }
.section__split-media img { border-radius: var(--radius); width: 75%; max-width: 100%; height: auto; margin: 0 auto; }
.section__split-content .card-grid--2 { grid-template-columns: 1fr; }

/* Botões */
.btn {
	display: inline-block;
	padding: 0.85rem 1.5rem;
	border-radius: var(--radius);
	font-weight: 600;
	text-decoration: none;
	text-align: center;
	transition: transform .15s ease, opacity .15s ease;
}
.btn:hover { text-decoration: none; opacity: .92; transform: translateY(-1px); }
.btn--primary { background: var(--color-primary); color: #fff; }
.btn--outline { background: transparent; color: var(--color-primary); border: 2px solid var(--color-primary); }

/* Header */
.site-header {
	position: sticky; top: 0; z-index: 50;
	background: #fff;
	border-bottom: 1px solid var(--color-border);
}
.site-header__inner {
	display: flex; align-items: center; justify-content: space-between;
	padding: 0.9rem 1.25rem;
}
.site-header__brand {
	display: flex;
	align-items: center;
	gap: 0.55rem;
	text-decoration: none;
	color: var(--color-primary-dark);
	line-height: 1.2;
}
.site-header__brand:hover { text-decoration: none; }

.brand__prefix {
	font-family: var(--font-brand);
	font-size: 0.95rem;
	font-weight: 400;
	color: var(--color-accent);
	letter-spacing: 0.04em;
	align-self: flex-start;
	padding-top: 0.1em;
}

.brand__name {
	font-family: var(--font-brand);
	font-size: 1rem;
	font-weight: 400;
	color: var(--color-primary-dark);
	letter-spacing: 0.01em;
}

.brand__name strong {
	font-weight: 700;
	display: block;
}
.site-header__toggle {
	display: flex; flex-direction: column; justify-content: center; gap: 5px;
	width: 40px; height: 40px; background: none; border: none; cursor: pointer;
}
.site-header__toggle span {
	display: block; width: 24px; height: 2px; background: var(--color-primary-dark);
}
.site-header__nav {
	position: fixed; top: 0; right: -100%; height: 100vh; width: min(320px, 85%);
	background: #fff; box-shadow: -4px 0 20px rgba(0,0,0,.12);
	padding: 5rem 1.5rem 2rem; transition: right .25s ease;
	display: flex; flex-direction: column; gap: 1.5rem; z-index: 60;
}
.site-header__nav.is-open { right: 0; }
.site-header__menu { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 1rem; }
.site-header__menu a { color: var(--color-text); font-weight: 500; }
.site-header__cta { align-self: flex-start; }

/* Hero */
.hero {
	position: relative; color: #fff; overflow: hidden;
	background: var(--color-primary-dark);
}
.hero__overlay {
	position: absolute; inset: 0;
	background: linear-gradient(160deg, rgba(8,58,54,.97) 0%, rgba(13,79,74,.82) 60%, rgba(13,79,74,.30) 100%);
	pointer-events: none;
}
.hero__inner {
	position: relative;
	display: flex; align-items: flex-end;
	padding: 0 1.25rem;
}
.hero__content {
	flex: 1; min-width: 0;
	padding: 4rem 0 3.5rem;
}
.hero__photo {
	flex-shrink: 0;
	display: none; /* mobile: oculta, aparece em desktop */
	align-self: flex-end;
	margin-left: 2rem;
}
.hero__photo img {
	display: block;
	width: 340px;
	height: auto;
	object-fit: cover;
	border-radius: var(--radius) var(--radius) 0 0;
	filter: drop-shadow(-8px 0 24px rgba(0,0,0,.35));
}
.hero__eyebrow {
	text-transform: uppercase; letter-spacing: .08em; font-size: .8rem;
	color: var(--color-accent); font-weight: 700; margin-bottom: .75rem;
}
.hero__title { color: #fff; font-size: 1.9rem; margin-bottom: 1rem; }
.hero__text { color: rgba(255,255,255,.9); font-size: 1.05rem; margin-bottom: 1.75rem; }

/* Cards */
.card-grid {
	display: grid; grid-template-columns: 1fr; gap: 1.25rem; margin-bottom: 1.75rem;
}
.card {
	background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius);
	padding: 1.5rem;
	border-top: 4px solid var(--color-primary);
}
.section--alt .card { background: #fff; }

.card--post { display: flex; flex-direction: column; gap: 0.75rem; }
.card__title { font-size: 1rem; margin: 0; }
.card__title a { color: var(--color-primary-dark); text-decoration: none; }
.card__title a:hover { color: var(--color-primary); text-decoration: underline; }
.card__excerpt { color: var(--color-text-muted); font-size: 0.92rem; margin: 0; flex: 1; }
.card__link { font-size: 0.88rem; font-weight: 600; color: var(--color-primary); margin-top: auto; }
.card__link:hover { text-decoration: underline; }

/* Estado vazio — sem posts */
.posts-empty {
	text-align: center; padding: 4rem 1rem;
	max-width: 480px; margin: 0 auto;
}
.posts-empty__icon { font-size: 2.5rem; margin-bottom: 1rem; }
.posts-empty__title { color: var(--color-primary-dark); margin-bottom: 0.75rem; }
.posts-empty__text { color: var(--color-text-muted); margin-bottom: 2rem; }

/* Paginação */
.page-numbers {
	display: inline-flex; gap: 0.5rem; flex-wrap: wrap;
	justify-content: center; margin-top: 2rem; width: 100%;
}
.page-numbers a,
.page-numbers span {
	padding: 0.45rem 0.85rem; border-radius: var(--radius);
	border: 1px solid var(--color-border); font-size: 0.9rem;
	color: var(--color-primary); text-decoration: none; transition: background .15s;
}
.page-numbers .current { background: var(--color-primary); color: #fff; border-color: var(--color-primary); }
.page-numbers a:hover { background: var(--color-bg-alt); text-decoration: none; }

/* Steps / Timeline / FAQ */
.steps { display: grid; grid-template-columns: 1fr; gap: 1.25rem; margin-bottom: 1.5rem; }
.steps__item {
	border-left: 3px solid var(--color-primary); padding-left: 1rem;
}
.timeline { display: flex; flex-direction: column; gap: 1.5rem; }
.timeline__item { border-left: 3px solid var(--color-accent); padding-left: 1rem; }
.faq { display: flex; flex-direction: column; gap: 1.25rem; }
.faq__item { border-bottom: 1px solid var(--color-border); padding-bottom: 1.25rem; }
.faq__item:last-child { border-bottom: none; }

/* CTA block */
.cta { background: var(--color-primary); color: #fff; padding: 3rem 0; text-align: center; }
.cta__title { color: #fff; }
.cta__text { color: rgba(255,255,255,.9); max-width: 560px; margin: 0 auto 1.5rem; }
.cta .btn--primary { background: #fff; color: var(--color-primary); }

/* Página padrão / legal */
.page-content { padding: 3rem 0; max-width: 780px; margin: 0 auto; }
.page-content--legal h2 { margin-top: 2rem; }
.page-title { margin-bottom: 1.5rem; }
.page-404 { padding: 5rem 0; text-align: center; }

/* Footer */
.site-footer { background: var(--color-primary-dark); color: rgba(255,255,255,.85); padding: 3rem 0 0; }
.site-footer a { color: #fff; }
.site-footer__inner {
	display: grid; grid-template-columns: 1fr; gap: 2rem; padding-bottom: 2rem;
}
.site-footer__brand { font-weight: 700; color: #fff; font-size: 1.1rem; }
.site-footer__menu { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: .5rem; }
.site-footer__disclaimer { font-size: .85rem; opacity: .75; }
.site-footer__bottom {
	border-top: 1px solid rgba(255,255,255,.12);
	padding: 1.25rem 0; font-size: .85rem; text-align: center;
}

/* Botão WhatsApp flutuante */
.whatsapp-float {
	position: fixed; right: 1.1rem; bottom: 1.1rem; z-index: 70;
	width: 58px; height: 58px; border-radius: 50%;
	background: var(--color-whatsapp); color: #fff;
	display: flex; align-items: center; justify-content: center;
	box-shadow: 0 6px 18px rgba(0,0,0,.25);
	transition: transform .15s ease;
}
.whatsapp-float:hover { transform: scale(1.06); text-decoration: none; }

/* ===== Tablet / Desktop (mobile-first breakpoints) ===== */
@media (min-width: 768px) {
	h1 { font-size: 2.4rem; }
	h2 { font-size: 1.75rem; }
	.hero__title { font-size: 2.6rem; }
	.hero__content { padding: 6rem 0 5rem; }
	.hero__photo { display: flex; }
	.card-grid--2, .card-grid { grid-template-columns: repeat(2, 1fr); }
	.steps { grid-template-columns: repeat(3, 1fr); }
	.site-footer__inner { grid-template-columns: repeat(3, 1fr); }
	.section__split { grid-template-columns: 1fr 1fr; gap: 2.5rem; }
}

@media (min-width: 1024px) {
	.site-header__toggle { display: none; }
	.site-header__nav {
		position: static; height: auto; width: auto; box-shadow: none;
		flex-direction: row; align-items: center; padding: 0; background: transparent;
	}
	.site-header__menu { flex-direction: row; gap: 1.75rem; }
	.card-grid { grid-template-columns: repeat(3, 1fr); }
}
