/*
Theme Name: Adoção Segura Renovada
Theme URI: https://adocaosegura.com.br/
Author: Adoção Segura
Description: Tema editorial, acolhedor e responsivo, criado para o acervo Adoção Segura.
Version: 1.2.1
Text Domain: adocao-segura-renovada
*/

:root {
  --ink: #173c42;
  --ink-soft: #42656a;
  --teal: #0b7475;
  --teal-dark: #07595b;
  --mint: #dff3ed;
  --mint-2: #eef9f5;
  --coral: #ef6a5b;
  --coral-dark: #d95447;
  --gold: #f4c95d;
  --cream: #fffaf2;
  --paper: #ffffff;
  --line: #dce9e6;
  --shadow: 0 18px 55px rgba(23, 60, 66, .12);
  --radius: 24px;
  --wrap: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--cream);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.7;
  text-rendering: optimizeLegibility;
}
body.nav-open { overflow: hidden; }
a { color: var(--teal); text-decoration-thickness: .08em; text-underline-offset: .18em; }
a:hover { color: var(--coral-dark); }
img { max-width: 100%; height: auto; }
button, input, textarea, select { font: inherit; }
.screen-reader-text {
  clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%); height: 1px; width: 1px;
  margin: -1px; overflow: hidden; padding: 0; position: absolute !important;
}
.skip-link:focus {
  clip: auto; clip-path: none; height: auto; width: auto; left: 1rem; top: 1rem; z-index: 9999;
  padding: .65rem 1rem; color: #fff; background: var(--ink); border-radius: 999px;
}
.wrap { width: min(calc(100% - 40px), var(--wrap)); margin-inline: auto; }
.narrow { width: min(calc(100% - 40px), 790px); margin-inline: auto; }

h1, h2, h3, h4 {
  margin: 0 0 .55em;
  color: var(--ink);
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.12;
  letter-spacing: -.025em;
}
h1 { font-size: clamp(2.45rem, 6vw, 5rem); }
h2 { font-size: clamp(2rem, 4.5vw, 3.45rem); }
h3 { font-size: clamp(1.3rem, 2.5vw, 1.75rem); }
p { margin: 0 0 1.2em; }

.eyebrow {
  display: inline-flex; align-items: center; gap: .55rem; margin-bottom: 1rem;
  color: var(--teal); font-size: .76rem; font-weight: 800; letter-spacing: .13em; text-transform: uppercase;
}
.eyebrow::before { content: ""; width: 28px; height: 3px; background: var(--coral); border-radius: 9px; }
.section-heading { max-width: 760px; margin-bottom: 2.35rem; }
.section-heading p { color: var(--ink-soft); font-size: 1.08rem; }
.section-space { padding-block: clamp(4.25rem, 8vw, 7.5rem); }
.soft-section { background: var(--mint-2); }

.button {
  display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
  min-height: 50px; padding: .78rem 1.28rem; border: 2px solid var(--teal); border-radius: 999px;
  color: #fff; background: var(--teal); font-weight: 800; text-decoration: none; transition: .2s ease;
}
.button:hover { color: #fff; background: var(--teal-dark); border-color: var(--teal-dark); transform: translateY(-2px); }
.button.button-coral { background: var(--coral); border-color: var(--coral); }
.button.button-coral:hover { background: var(--coral-dark); border-color: var(--coral-dark); }
.button.button-light { color: var(--ink); background: #fff; border-color: #fff; }
.button.button-light:hover { color: var(--teal-dark); background: var(--mint); border-color: var(--mint); }
.text-link { display: inline-flex; align-items: center; gap: .45rem; font-weight: 800; text-decoration: none; }
.text-link::after { content: "→"; transition: transform .2s ease; }
.text-link:hover::after { transform: translateX(4px); }

/* Header */
.site-header {
  position: sticky; z-index: 900; top: 0; background: rgba(255,250,242,.93);
  border-bottom: 1px solid rgba(11,116,117,.1); backdrop-filter: blur(18px);
}
.header-inner { min-height: 84px; display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; }
.brand { display: inline-flex; align-items: center; color: var(--ink); text-decoration: none; }
.brand-mark {
  width: 48px; height: 48px; display: grid; place-items: center; color: #fff;
  background: var(--teal); border-radius: 16px 16px 16px 5px; box-shadow: 0 9px 22px rgba(11,116,117,.22);
}
.brand-mark svg { width: 29px; height: 29px; }
.brand-copy strong { display: block; font-family: Georgia, serif; font-size: 1.42rem; line-height: 1; }
.brand-copy small { display: block; margin-top: .3rem; color: var(--ink-soft); font-size: .7rem; letter-spacing: .07em; text-transform: uppercase; }
.primary-menu, .primary-menu ul { margin: 0; padding: 0; list-style: none; }
.primary-menu { display: flex; align-items: center; gap: .2rem; }
.primary-menu a {
  display: block; padding: .7rem .78rem; color: var(--ink); font-size: .9rem; font-weight: 750; text-decoration: none; border-radius: 999px;
}
.primary-menu a:hover, .primary-menu .current-menu-item > a { color: var(--teal-dark); background: var(--mint); }
.nav-toggle {
  display: none; width: 48px; height: 48px; border: 0; color: var(--ink); background: var(--mint); border-radius: 15px; cursor: pointer;
}
.nav-toggle span { display: block; width: 22px; height: 2px; margin: 5px auto; background: currentColor; transition: .2s ease; }

/* Hero slider */
.hero { position: relative; overflow: hidden; background: var(--ink); }
.hero-slider { position: relative; min-height: clamp(740px, 84vh, 880px); }
.hero-slide {
  position: absolute; inset: 0; display: grid; align-items: center; opacity: 0; visibility: hidden;
  transition: opacity .75s ease, visibility .75s ease;
}
.hero-slide.is-active { opacity: 1; visibility: visible; }
.hero-slide::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(8,45,49,.93) 0%, rgba(8,45,49,.73) 45%, rgba(8,45,49,.22) 100%); z-index: 1; }
.hero-slide::after { content: ""; position: absolute; inset: auto -10% -52% 32%; height: 70%; background: rgba(239,106,91,.17); border-radius: 50%; filter: blur(2px); z-index: 1; }
.hero-media { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-content { position: relative; z-index: 2; width: min(740px, 72%); padding-block: 5rem 11rem; color: #fff; }
.hero-content h1 { color: #fff; font-size: clamp(2.8rem, 5.2vw, 4.65rem); text-wrap: balance; }
.hero-content p { max-width: 650px; font-size: clamp(1.05rem, 2vw, 1.3rem); color: rgba(255,255,255,.9); }
.hero-content .eyebrow { color: var(--gold); }
.hero-actions { position: relative; z-index: 6; display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.5rem; }
.slider-nav {
  position: absolute; z-index: 4; left: max(20px, calc((100% - var(--wrap)) / 2)); bottom: 3.25rem;
  display: flex; align-items: center; gap: .7rem;
}
.slider-dot { width: 11px; height: 11px; padding: 0; border: 2px solid #fff; border-radius: 50%; background: transparent; cursor: pointer; }
.slider-dot.is-active { width: 34px; border-radius: 999px; background: var(--gold); border-color: var(--gold); }
.hero-wave { position: absolute; z-index: 3; right: -5%; bottom: -60px; width: 55%; height: 130px; background: var(--cream); border-radius: 60% 0 0 0 / 100% 0 0 0; }

/* Home sections */
.trust-strip { position: relative; z-index: 5; margin-top: -22px; }
.trust-grid { display: grid; grid-template-columns: repeat(3, 1fr); background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.trust-item { min-width: 0; padding: 1.35rem 1.5rem; display: flex; align-items: center; gap: 1rem; }
.trust-item + .trust-item { border-left: 1px solid var(--line); }
.trust-icon {
  width: 62px; height: 62px; flex: 0 0 62px; display: grid; place-items: center; overflow: hidden;
  background: linear-gradient(145deg, #f4fcf9, var(--mint)); border: 1px solid rgba(11,116,117,.11); border-radius: 18px;
}
.trust-icon img { width: 56px; height: 56px; object-fit: contain; filter: drop-shadow(0 5px 7px rgba(23,60,66,.14)); }
.trust-item strong { display: block; font-size: 1.05rem; }
.trust-item span { display: block; color: var(--ink-soft); font-size: .85rem; line-height: 1.35; }
.path-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
.path-card {
  min-height: 285px; padding: 2rem; display: flex; flex-direction: column; align-items: flex-start;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 10px 35px rgba(23,60,66,.06); transition: .25s ease;
}
.path-card:hover { transform: translateY(-7px); box-shadow: var(--shadow); }
.path-card:nth-child(2) { background: var(--mint); }
.path-card:nth-child(3) { color: #fff; background: var(--teal); border-color: var(--teal); }
.path-card:nth-child(3) h3, .path-card:nth-child(3) a { color: #fff; }
.path-card:nth-child(3) p { color: rgba(255,255,255,.82); }
.path-number { margin-bottom: auto; color: var(--coral); font-family: Georgia, serif; font-size: 2.4rem; line-height: 1; }
.path-card p { color: var(--ink-soft); }
.about-grid { display: grid; grid-template-columns: .9fr 1.1fr; align-items: center; gap: clamp(2.5rem, 7vw, 6.5rem); }
.about-photo { position: relative; }
.about-photo img { width: 100%; aspect-ratio: 4/4.25; object-fit: cover; border-radius: 45% 45% 24px 24px; box-shadow: var(--shadow); }
.about-photo::before { content: ""; position: absolute; z-index: -1; inset: -22px 20% 18% -22px; background: var(--gold); border-radius: 50% 50% 18px 18px; }
.about-badge { position: absolute; right: -22px; bottom: 34px; max-width: 185px; padding: 1.1rem; color: #fff; background: var(--coral); border-radius: 18px; box-shadow: var(--shadow); font-weight: 800; line-height: 1.3; }
.about-lede { max-width: 620px; color: var(--ink-soft); font-size: 1.05rem; }
.about-illustration { margin: 1.4rem 0 1.5rem; overflow: hidden; background: var(--mint-2); border: 1px solid var(--line); border-radius: 28px; box-shadow: var(--shadow); }
.about-illustration img { display: block; width: 100%; height: auto; }
.about-actions { margin-bottom: 0; }

.posts-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.35rem; }
.post-card { overflow: hidden; background: #fff; border: 1px solid var(--line); border-radius: 22px; box-shadow: 0 10px 30px rgba(23,60,66,.07); transition: .25s ease; }
.post-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.post-card-media { display: block; position: relative; overflow: hidden; aspect-ratio: 16/10; background: var(--mint); }
.post-card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .45s ease; }
.post-card:hover .post-card-media img { transform: scale(1.045); }
.post-card-body { padding: 1.35rem 1.4rem 1.55rem; }
.post-card-meta { margin-bottom: .7rem; color: var(--coral-dark); font-size: .75rem; font-weight: 850; letter-spacing: .08em; text-transform: uppercase; }
.post-card h3 { font-size: 1.38rem; }
.post-card h3 a { color: var(--ink); text-decoration: none; }
.post-card p { color: var(--ink-soft); font-size: .94rem; }
.gallery-ribbon { display: grid; grid-template-columns: 1.4fr .8fr .8fr; grid-template-rows: 230px 230px; gap: .8rem; }
.gallery-ribbon a { overflow: hidden; border-radius: 20px; }
.gallery-ribbon a:first-child { grid-row: 1 / 3; }
.gallery-ribbon img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease, filter .4s ease; }
.gallery-ribbon a:hover img { transform: scale(1.05); filter: saturate(1.15); }
.cta-panel {
  position: relative; overflow: hidden; padding: clamp(2.5rem, 6vw, 5rem); color: #fff; background: var(--ink); border-radius: 32px;
}
.cta-panel::after { content: "♥"; position: absolute; right: 4%; top: -42%; color: rgba(244,201,93,.12); font-size: 26rem; line-height: 1; transform: rotate(-10deg); }
.cta-panel > * { position: relative; z-index: 1; }
.cta-panel h2 { max-width: 720px; color: #fff; }
.cta-panel p { max-width: 680px; color: rgba(255,255,255,.78); font-size: 1.08rem; }

/* Internal pages */
.page-hero {
  position: relative; min-height: 390px; padding-block: clamp(4.5rem, 8vw, 7rem); display: grid; align-items: center;
  color: #fff; background-color: var(--ink); background-image: linear-gradient(90deg, rgba(8,45,49,.94) 0%, rgba(8,45,49,.76) 48%, rgba(8,45,49,.3) 100%), var(--page-hero-image);
  background-position: center; background-size: cover;
}
.page-hero .wrap { position: relative; z-index: 1; }
.page-hero h1 { max-width: 780px; color: #fff; }
.page-hero .eyebrow { color: var(--gold); }
.page-hero p { max-width: 720px; color: rgba(255,255,255,.88); font-size: 1.12rem; }
.content-shell { padding-block: clamp(3rem, 7vw, 6rem); }
.page-content .entry-content > h1:first-child { display: none; }
.entry-content { font-size: 1.03rem; }
.entry-content > * { max-width: 100%; }
.entry-content h2, .entry-content h3 { margin-top: 1.6em; }
.entry-content img { border-radius: 16px; }
.entry-content figure { margin: 2rem 0; }
.entry-content blockquote { margin: 2rem 0; padding: 1.4rem 1.6rem; background: var(--mint); border-left: 5px solid var(--teal); border-radius: 0 18px 18px 0; font-family: Georgia, serif; font-size: 1.2rem; }
.entry-content table { width: 100%; border-collapse: collapse; }
.entry-content th, .entry-content td { padding: .75rem; border: 1px solid var(--line); text-align: left; }
.entry-content .gallery { width: 100% !important; display: grid !important; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.entry-content .gallery::before, .entry-content .gallery::after { display: none !important; }
.entry-content .gallery-item { min-width: 0; width: auto !important; margin: 0 !important; float: none !important; padding: .85rem; background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: 0 10px 28px rgba(23,60,66,.08); }
.entry-content .gallery-icon, .entry-content .gallery a { display: block; width: 100%; }
.entry-content .gallery img { display: block; width: 100% !important; height: 260px !important; max-width: 100% !important; object-fit: contain; aspect-ratio: auto; border: 0 !important; border-radius: 12px; background: var(--mint-2); }
.entry-content .gallery-caption { margin-top: .7rem; color: var(--ink-soft); font-size: .84rem; line-height: 1.4; }
.page-content-publicacoes .narrow, .page-content-imagens .narrow { width: min(calc(100% - 40px), 1040px); }
.single-wrap { width: min(calc(100% - 40px), 840px); margin-inline: auto; }
.single-head { padding-block: clamp(3.5rem, 7vw, 6rem) 2.5rem; }
.single-head h1 { font-size: clamp(2.3rem, 5.7vw, 4.6rem); }
.single-meta { display: flex; flex-wrap: wrap; gap: .6rem 1.2rem; color: var(--ink-soft); font-size: .87rem; font-weight: 700; }
.single-featured { width: min(calc(100% - 40px), 1080px); margin: 0 auto 3rem; display: flex; justify-content: center; }
.single-featured img { display: block; width: auto; max-width: 100%; height: auto; max-height: 780px; object-fit: contain; border-radius: 28px; box-shadow: var(--shadow); }
.share-box { margin-top: 3.5rem; padding: 1.4rem; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; background: var(--mint); border-radius: 18px; }
.share-links { display: flex; gap: .5rem; }
.share-links a { display: grid; place-items: center; min-width: 42px; height: 42px; padding-inline: .8rem; color: #fff; background: var(--teal); border-radius: 999px; font-size: .78rem; font-weight: 800; text-decoration: none; }
.post-nav { margin-top: 3.5rem; padding-top: 2rem; display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; border-top: 1px solid var(--line); }
.post-nav a { padding: 1.1rem; color: var(--ink); background: #fff; border: 1px solid var(--line); border-radius: 16px; font-weight: 750; text-decoration: none; }
.archive-head { padding-block: clamp(4rem, 8vw, 7rem) 3rem; }
.archive-head h1 { max-width: 880px; }
.pagination { margin-top: 3rem; }
.pagination .nav-links { display: flex; flex-wrap: wrap; justify-content: center; gap: .45rem; }
.pagination a, .pagination span { min-width: 42px; height: 42px; display: grid; place-items: center; padding-inline: .7rem; border-radius: 999px; background: #fff; border: 1px solid var(--line); text-decoration: none; }
.pagination .current { color: #fff; background: var(--teal); border-color: var(--teal); }
.empty-state { padding: 3rem; text-align: center; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); }

/* Footer */
.site-footer { margin-top: 6rem; color: rgba(255,255,255,.78); background: #102f34; }
.footer-main { padding-block: 4.5rem 3rem; display: grid; grid-template-columns: 1.3fr .7fr .8fr; gap: 3rem; }
.footer-main h3 { color: #fff; font-size: 1.1rem; font-family: inherit; letter-spacing: 0; }
.footer-brand { color: #fff; }
.footer-brand .brand-copy small { color: rgba(255,255,255,.62); }
.footer-about { max-width: 450px; margin-top: 1.2rem; }
.footer-links { margin: 0; padding: 0; list-style: none; }
.footer-links a { color: rgba(255,255,255,.8); text-decoration: none; }
.footer-links a:hover { color: var(--gold); }
.footer-bottom { padding-block: 1.25rem; border-top: 1px solid rgba(255,255,255,.1); font-size: .82rem; }

@media (max-width: 980px) {
  .nav-toggle { display: block; }
  .site-nav {
    position: fixed; inset: 84px 0 auto; max-height: calc(100vh - 84px); overflow: auto; padding: 1.1rem 20px 2rem;
    background: var(--cream); border-bottom: 1px solid var(--line); transform: translateY(-125%); opacity: 0; visibility: hidden; transition: .25s ease;
  }
  .site-nav.is-open { transform: translateY(0); opacity: 1; visibility: visible; }
  .primary-menu { width: min(100%, var(--wrap)); margin: auto; display: block; }
  .primary-menu a { padding: .9rem 1rem; font-size: 1rem; }
  .path-grid, .posts-grid { grid-template-columns: repeat(2, 1fr); }
  .about-grid { grid-template-columns: .85fr 1.15fr; gap: 3rem; }
  .footer-main { grid-template-columns: 1fr 1fr; }
  .footer-main > :first-child { grid-column: 1 / -1; }
}

@media (max-width: 700px) {
  .wrap, .narrow, .single-wrap, .single-featured { width: min(calc(100% - 28px), var(--wrap)); }
  .brand-copy small { display: none; }
  .hero-slider { min-height: 660px; }
  .hero-slide::before { background: linear-gradient(90deg, rgba(8,45,49,.92), rgba(8,45,49,.65)); }
  .hero-content { width: 100%; padding-block: 7rem 9rem; }
  .hero-wave { display: none; }
  .trust-grid, .path-grid, .posts-grid, .about-grid, .footer-main { grid-template-columns: 1fr; }
  .trust-item + .trust-item { border-left: 0; border-top: 1px solid var(--line); }
  .about-photo { max-width: 470px; }
  .about-badge { right: 8px; }
  .gallery-ribbon { grid-template-columns: 1fr 1fr; grid-template-rows: 230px 180px; }
  .gallery-ribbon a:first-child { grid-column: 1 / 3; grid-row: auto; }
  .footer-main > :first-child { grid-column: auto; }
  .post-nav { grid-template-columns: 1fr; }
  .entry-content .gallery { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 520px) {
  .entry-content .gallery { grid-template-columns: 1fr; }
  .entry-content .gallery img { height: 300px !important; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .001ms !important; animation-duration: .001ms !important; }
}
