/*
Theme Name: Central de Procedimentos Clínica Instituto VR
Theme URI: https://clinica.institutovr.com.br
Author: VERAX Aceleradora Empresarial
Description: Tema nativo para central interna de procedimentos.
Version: 2.2.0
Requires at least: 6.4
Requires PHP: 8.0
Text Domain: sante-help
*/

:root {
    --ink: #17251f;
    --muted: #67766e;
    --line: #d9e2ff;
    --brand: #2142e7;
    --brand-dark: #152db7;
    --accent: #6c8dff;
    --soft: #eef3ff;
    --paper: #ffffff;
    --shadow: 0 14px 40px rgba(33, 66, 231, .08);
    --radius: 18px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    color: var(--ink);
    background: #fff;
    font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 16px;
    line-height: 1.65;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; }
button, input { font: inherit; }
.container { width: min(1180px, calc(100% - 40px)); margin-inline: auto; }
.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; }

.site-header {
    height: 74px;
    background: var(--brand);
    color: #fff;
    border-bottom: 1px solid rgba(255,255,255,.12);
    display: flex;
    align-items: center;
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 28px; }
.site-brand { display: flex; align-items: center; gap: 12px; font-weight: 850; font-size: 20px; letter-spacing: -.35px; }
.brand-mark {
    width: 36px; height: 36px; border: 1px solid rgba(255,255,255,.28);
    border-radius: 11px; display: grid; place-items: center; color: #f3d58e; font-family: Georgia, serif; font-size: 20px;
}
.header-actions { display: flex; align-items: center; gap: 18px; font-size: 13px; }
.access-name { color: #d6e6df; }
.access-name strong { color: #fff; }
.logout-link { border: 1px solid rgba(255,255,255,.26); border-radius: 9px; padding: 8px 12px; transition: .2s; }
.logout-link:hover { background: rgba(255,255,255,.1); }
.menu-toggle { display: none; border: 0; background: transparent; color: #fff; padding: 6px; cursor: pointer; }

.hero {
    background: var(--brand);
    color: #fff;
    padding: 76px 0 86px;
    position: relative;
    overflow: hidden;
}
.hero:after {
    content: ""; position: absolute; width: 480px; height: 480px; border-radius: 50%;
    border: 1px solid rgba(255,255,255,.09); right: -230px; top: -260px;
    box-shadow: 0 0 0 72px rgba(255,255,255,.022), 0 0 0 144px rgba(255,255,255,.016);
}
.hero-inner { position: relative; z-index: 1; text-align: center; }
.eyebrow { color: #f0cd78; text-transform: uppercase; letter-spacing: .16em; font-size: 12px; font-weight: 800; }
.hero h1 { font-family: Georgia, serif; margin: 12px 0 18px; font-size: clamp(38px, 5vw, 62px); line-height: 1.1; letter-spacing: -1.8px; font-weight: 500; }
.hero p { color: #d4e3dc; font-size: 18px; margin: 0 auto 30px; max-width: 640px; }
.search-form {
    max-width: 720px; margin: 0 auto; background: #fff; border-radius: 15px; height: 64px;
    padding: 7px 8px 7px 22px; display: flex; align-items: center; gap: 12px; box-shadow: 0 12px 36px rgba(0,0,0,.18);
}
.search-form svg { color: #718078; flex: 0 0 auto; }
.search-form input { flex: 1; min-width: 0; border: 0; outline: 0; font-size: 16px; color: var(--ink); background: transparent; }
.search-form button { border: 0; background: var(--brand); color: #fff; height: 48px; padding: 0 22px; border-radius: 10px; font-weight: 800; cursor: pointer; }
.search-form button:hover { background: var(--brand-dark); }

.main-content { padding: 66px 0 90px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 24px; }
.section-heading h2 { margin: 0; font-size: 28px; letter-spacing: -.8px; }
.section-heading p { margin: 4px 0 0; color: var(--muted); }
.section-heading a { color: var(--brand); font-size: 14px; font-weight: 800; }
.area-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.area-card {
    border: 1px solid var(--line); border-radius: var(--radius); padding: 25px; background: var(--paper);
    min-height: 186px; display: flex; flex-direction: column; transition: .23s ease; position: relative; overflow: hidden;
}
.area-card:hover { transform: translateY(-4px); border-color: #b6ccc0; box-shadow: var(--shadow); }
.area-icon { width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center; background: var(--soft); color: var(--brand); margin-bottom: 22px; font-weight: 850; }
.area-card h3 { margin: 0 0 6px; font-size: 19px; letter-spacing: -.25px; }
.area-card p { color: var(--muted); font-size: 14px; line-height: 1.5; margin: 0 0 18px; }
.area-meta { margin-top: auto; font-size: 12px; color: #7b8982; display: flex; align-items: center; justify-content: space-between; }
.area-arrow { color: var(--brand); font-size: 20px; }

.recent-section { margin-top: 64px; padding-top: 50px; border-top: 1px solid var(--line); }
.article-list { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.article-row { display: grid; grid-template-columns: 1fr auto; gap: 20px; align-items: center; padding: 20px 22px; border-bottom: 1px solid var(--line); transition: .18s; }
.article-row:last-child { border-bottom: 0; }
.article-row:hover { background: var(--soft); }
.article-row h3 { font-size: 16px; margin: 0 0 4px; letter-spacing: -.1px; }
.article-row p { color: var(--muted); font-size: 13px; margin: 0; }
.article-row time { color: #7c8982; font-size: 12px; white-space: nowrap; }

.page-head { background: var(--soft); border-bottom: 1px solid var(--line); padding: 36px 0 42px; }
.breadcrumbs { font-size: 13px; color: var(--muted); display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 21px; }
.breadcrumbs a:hover { color: var(--brand); }
.page-head h1 { margin: 0 0 9px; font-size: clamp(32px, 4vw, 46px); letter-spacing: -1.5px; line-height: 1.15; }
.page-head p { margin: 0; color: var(--muted); max-width: 680px; }
.page-search { margin-top: 26px; max-width: 620px; box-shadow: none; border: 1px solid var(--line); height: 56px; }
.page-search button { height: 42px; }
.collection-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin-bottom: 42px; }
.collection-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; transition: .2s; }
.collection-card:hover { box-shadow: var(--shadow); border-color: #b6ccc0; }
.collection-card h2 { font-size: 19px; margin: 0 0 6px; }
.collection-card p { margin: 0 0 14px; color: var(--muted); font-size: 14px; }
.collection-card span { font-size: 12px; font-weight: 750; color: var(--brand); }

.article-layout { display: grid; grid-template-columns: 250px minmax(0, 760px) 190px; gap: 42px; align-items: start; }
.article-sidebar, .article-toc { position: sticky; top: 28px; }
.sidebar-title, .toc-title { text-transform: uppercase; font-size: 11px; letter-spacing: .12em; color: #829088; font-weight: 850; margin-bottom: 12px; }
.sidebar-tree { list-style: none; padding: 0; margin: 0; }
.sidebar-tree li { margin: 2px 0; }
.sidebar-tree a { display: block; border-radius: 8px; padding: 8px 10px; font-size: 13px; color: #506057; }
.sidebar-tree a:hover, .sidebar-tree a.is-current { background: var(--soft); color: var(--brand); font-weight: 750; }
.sidebar-tree .tree-child { padding-left: 14px; border-left: 1px solid var(--line); margin-left: 10px; }
.article-main { min-width: 0; }
.article-main .breadcrumbs { margin-bottom: 24px; }
.article-main h1 { font-size: clamp(34px, 4.5vw, 50px); line-height: 1.1; letter-spacing: -1.6px; margin: 0 0 18px; }
.article-excerpt { font-size: 19px; color: var(--muted); margin-bottom: 22px; }
.article-meta { display: flex; flex-wrap: wrap; gap: 10px 22px; padding: 14px 0 25px; border-bottom: 1px solid var(--line); color: #748179; font-size: 12px; margin-bottom: 34px; }
.article-content { font-size: 17px; color: #29372f; }
.article-content h2 { font-size: 29px; line-height: 1.25; letter-spacing: -.7px; margin: 52px 0 16px; scroll-margin-top: 25px; }
.article-content h3 { font-size: 22px; line-height: 1.3; margin: 38px 0 12px; scroll-margin-top: 25px; }
.article-content p { margin: 0 0 20px; }
.article-content ul, .article-content ol { padding-left: 24px; margin: 0 0 24px; }
.article-content li { margin-bottom: 8px; }
.article-content img { border-radius: 12px; border: 1px solid var(--line); box-shadow: 0 8px 26px rgba(21,56,44,.08); }
.article-content video, .article-content iframe { max-width: 100%; border-radius: 12px; overflow: hidden; }
.article-content blockquote { margin: 26px 0; padding: 18px 22px; border-left: 4px solid var(--accent); background: #fcf8ee; border-radius: 0 10px 10px 0; }
.article-content .wp-block-file { background: var(--soft); padding: 16px; border-radius: 10px; }
.article-toc nav a { display: block; font-size: 12px; line-height: 1.4; color: #67766e; padding: 6px 0 6px 12px; border-left: 2px solid var(--line); }
.article-toc nav a:hover, .article-toc nav a.is-active { color: var(--brand); border-color: var(--brand); }
.article-toc nav a.toc-h3 { padding-left: 22px; }
.article-feedback { margin-top: 56px; border-top: 1px solid var(--line); padding-top: 26px; color: var(--muted); font-size: 13px; }

.empty-state { text-align: center; background: var(--soft); padding: 48px 24px; border-radius: var(--radius); }
.empty-state h2 { margin-top: 0; }
.search-title em { color: var(--brand); font-style: normal; }
.result-count { color: var(--muted); margin-bottom: 24px; }
.back-link { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 800; color: var(--brand); margin-top: 25px; }

.site-footer { background: #102f25; color: #c9d9d1; padding: 34px 0; font-size: 13px; }
.footer-inner { display: flex; justify-content: space-between; gap: 24px; }
.site-footer a:hover { color: #fff; }

@media (max-width: 1050px) {
    .article-layout { grid-template-columns: 220px minmax(0, 1fr); }
    .article-toc { display: none; }
}
@media (max-width: 780px) {
    .container { width: min(100% - 28px, 1180px); }
    .site-header { height: 66px; }
    .access-name { display: none; }
    .hero { padding: 54px 0 62px; }
    .hero p { font-size: 16px; }
    .search-form { height: 58px; padding-left: 16px; }
    .search-form button { padding: 0 16px; height: 44px; }
    .main-content { padding: 44px 0 64px; }
    .area-grid, .collection-grid { grid-template-columns: 1fr; }
    .area-card { min-height: 0; }
    .article-layout { grid-template-columns: 1fr; gap: 20px; }
    .article-sidebar { position: static; min-width: 0; overflow: hidden; }
    .sidebar-title { display: none; }
    .sidebar-tree { display: flex; width: 100%; max-width: 100%; overflow-x: auto; gap: 8px; padding-bottom: 8px; }
    .sidebar-tree li { flex: 0 0 auto; }
    .sidebar-tree a { border: 1px solid var(--line); white-space: nowrap; }
    .sidebar-tree .tree-child { display: none; }
    .article-main h1 { font-size: 36px; }
    .article-content { font-size: 16px; }
    .article-content h2 { font-size: 25px; }
    .footer-inner { display: block; }
    .footer-inner div + div { margin-top: 8px; }
}
@media (max-width: 480px) {
    .site-brand span:last-child { display: none; }
    .logout-link { padding: 7px 10px; }
    .hero h1 { font-size: 37px; }
    .search-form button span { display: none; }
    .search-form button { width: 44px; padding: 0; }
    .search-form button::before { content: "→"; font-size: 20px; line-height: 1; }
    .section-heading { align-items: start; }
    .article-row { grid-template-columns: 1fr; gap: 8px; }
}

/* Visual system aligned with the help-center reference. */
:root {
    --ink: #000000;
    --muted: #3c3c3c;
    --line: #ebebeb;
    --brand: #2142e7;
    --brand-dark: #001fc4;
    --accent: #2142e7;
    --soft: #f5f5f5;
    --paper: #ffffff;
    --shadow: 0 2px 8px rgba(0, 0, 0, .06);
    --radius: 10px;
}

body {
    color: #000;
    background: #fff;
    font-family: proxima-nova, "Helvetica Neue", system-ui, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 16px;
    line-height: 1.35;
}

.container { width: min(945px, calc(100% - 40px)); }

.site-header {
    display: block;
    height: 208px;
    padding-top: 32px;
    color: #fff;
    background: linear-gradient(118deg, #0828c9 0%, #2142e7 100%);
    border: 0;
}
.home .site-header { height: 102px; }
.header-inner { height: 46px; }
.site-brand {
    display: block;
    min-width: 0;
    font-size: 0;
}
.site-brand .sante-brand-logo {
    display: block;
    width: auto;
    max-width: 170px;
    height: auto;
    max-height: 34px;
    object-fit: contain;
    object-position: left center;
}
.site-brand .sante-brand-logo.is-force-white {
    filter: brightness(0) invert(1);
}
.site-brand .sante-brand-wordmark {
    display: block;
    color: #fff;
    font-size: 17px;
    font-weight: 800;
    line-height: 34px;
    letter-spacing: .01em;
}
.header-actions { gap: 16px; font-size: 14px; }
.access-name { display: none; color: rgba(255,255,255,.82); }
.access-name strong { color: #fff; font-weight: 600; }
.logout-link { padding: 0; border: 0; border-radius: 0; color: #fff; }
.logout-link:hover { background: transparent; text-decoration: underline; }
.header-search .search-form { max-width: none; width: 100%; margin-top: 24px; }

.hero {
    height: 356px;
    padding: 76px 0 0;
    color: #fff;
    background: linear-gradient(118deg, #0828c9 0%, #2142e7 100%);
}
.hero::after { display: none; }
.hero h1 {
    margin: 0 0 24px;
    color: #fff;
    font-family: inherit;
    font-size: 28px;
    font-weight: 600;
    line-height: 35px;
    letter-spacing: 0;
}
.hero p, .hero .eyebrow { display: none; }

.search-form,
.page-search {
    width: 620px;
    max-width: 100%;
    height: 66px;
    margin: 0 auto;
    padding: 0 20px;
    gap: 20px;
    border: 0;
    border-radius: 12px;
    background: rgba(255, 255, 255, .2);
    box-shadow: none;
}
.search-form svg { width: 24px; height: 24px; color: #fff; }
.search-form input {
    color: #fff;
    font-size: 18px;
    line-height: 18px;
}
.search-form input::placeholder { color: rgba(255,255,255,.78); opacity: 1; }
.search-form button { display: none; }

.home .main-content { padding: 40px 0 115px; }
.home .main-content .container { width: min(885px, calc(100% - 40px)); }
.area-grid { grid-template-columns: repeat(3, 1fr); gap: 30px; }
.area-card {
    display: block;
    min-height: 240px;
    padding: 30px;
    border: 1px solid #ebebeb;
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,.06);
}
.area-card:hover {
    transform: none;
    border-color: #dcdcdc;
    box-shadow: 0 4px 14px rgba(0,0,0,.09);
}
.area-icon {
    width: 28px;
    height: 28px;
    margin: 0 0 24px;
    border-radius: 0;
    color: #fff;
    background: linear-gradient(145deg, #2142e7, #80a5ff);
    font-size: 11px;
    font-weight: 700;
}
.area-card h3 {
    margin: 0 0 8px;
    color: #000;
    font-size: 16px;
    font-weight: 600;
    line-height: 21px;
    letter-spacing: 0;
}
.area-card p {
    margin: 0;
    color: #3c3c3c;
    font-size: 16px;
    line-height: 22px;
}
.area-meta, .recent-section { display: none; }

.page-head {
    padding: 40px 0 30px;
    background: #fff;
    border: 0;
}
.page-head .breadcrumbs { margin: 0 0 35px; }
.breadcrumbs {
    gap: 10px;
    color: #3c3c3c;
    font-size: 14px;
    line-height: 20px;
}
.breadcrumbs span { color: #8c8c8c; }
.page-head h1 {
    margin: 0 0 12px;
    color: #000;
    font-size: 28px;
    font-weight: 700;
    line-height: 28px;
    letter-spacing: 0;
}
.page-head p {
    color: #3c3c3c;
    font-size: 16px;
    line-height: 22px;
}
.page-head + .main-content { padding: 10px 0 90px; }

.collection-grid,
.article-list {
    display: block;
    margin: 0 0 20px;
    padding: 10px;
    overflow: visible;
    border: 0;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 0 0 1px rgba(0,0,0,.08), 0 2px 8px rgba(0,0,0,.04);
}
.collection-card,
.article-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 46px;
    margin: 0;
    padding: 15px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    box-shadow: none;
}
.collection-card:hover,
.article-row:hover {
    transform: none;
    border: 0;
    background: #f5f5f5;
    box-shadow: none;
}
.collection-card h2,
.article-row h3 {
    margin: 0;
    color: #000;
    font-size: 16px;
    font-weight: 400;
    line-height: 16px;
    letter-spacing: 0;
}
.collection-card span {
    display: none;
}
.article-row p, .article-row time { display: none; }
.empty-state { background: #f5f5f5; border-radius: 12px; }

.single-sante_pop .main-content { padding: 40px 0 100px; }
.article-layout {
    grid-template-columns: minmax(0, 700px) 190px;
    gap: 55px;
}
.article-main .breadcrumbs {
    height: 20px;
    margin: 0 0 45px;
    overflow: hidden;
    flex-wrap: nowrap;
    white-space: nowrap;
}
.article-main h1 {
    margin: 0 0 10px;
    color: #000;
    font-size: 32px;
    font-weight: 700;
    line-height: 32px;
    letter-spacing: 0;
}
.article-excerpt {
    margin: 0;
    color: #8c8c8c;
    font-size: 17px;
    line-height: 24px;
}
.article-excerpt p { margin: 0; }
.article-actions { margin-top: 22px; }
.docx-download {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 42px;
    padding: 0 16px;
    border: 1px solid #2142e7;
    border-radius: 10px;
    color: #2142e7;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    transition: .18s ease;
}
.docx-download:hover {
    color: #fff;
    background: #2142e7;
}
.article-meta { display: none; }
.article-content {
    margin-top: 48px;
    color: #3c3c3c;
    font-size: 16px;
    line-height: 1.6;
}
.article-content h2 {
    margin: 42px 0 20px;
    color: #3c3c3c;
    font-size: 22px;
    font-weight: 700;
    line-height: 29px;
    letter-spacing: 0;
}
.article-content h3 {
    margin: 34px 0 16px;
    color: #3c3c3c;
    font-size: 19px;
    line-height: 26px;
}
.article-content a { color: #2142e7; text-decoration: underline; }
.article-content img,
.article-content video,
.article-content iframe {
    border: 0;
    border-radius: 8px;
    box-shadow: none;
}
.article-toc { margin-top: 65px; }
.article-toc .toc-title { display: none; }
.article-toc nav a {
    padding: 8px 0 8px 24px;
    border-left: 1px solid #ebebeb;
    color: #8c8c8c;
    font-size: 14px;
    line-height: 18px;
}
.article-toc nav a:hover,
.article-toc nav a.is-active {
    border-left: 2px solid #000;
    color: #000;
}
.article-feedback {
    display: none;
}

.sante-docx-content {
    color: #26322c;
}
.sante-docx-content .pop-document-title {
    margin: 20px 0;
    line-height: 1.1;
    text-align: center;
}
.sante-docx-content .pop-kicker {
    margin: 58px 0 6px;
    color: #2d9a62;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
}
.sante-docx-content .pop-section-title {
    margin-top: 4px;
}
.sante-docx-content .pop-table-wrap {
    width: 100%;
    margin: 24px 0 34px;
    overflow-x: auto;
    border-radius: 8px;
    -webkit-overflow-scrolling: touch;
}
.sante-docx-content .pop-table {
    width: 100%;
    border-collapse: collapse;
    border-spacing: 0;
}
.sante-docx-content .pop-table td,
.sante-docx-content .pop-table th {
    min-width: 112px;
    vertical-align: top;
    font-size: 12px;
    line-height: 1.35;
}
.sante-docx-content .pop-table p {
    margin: 0;
}
.sante-docx-content img {
    display: block;
    width: 100%;
    height: auto;
    margin: 24px 0 34px;
}

.search-title em, .back-link { color: #2142e7; }
.site-footer {
    padding: 28px 0;
    border-top: 1px solid #f5f5f5;
    background: #fff;
    color: #8c8c8c;
}

@media (max-width: 980px) {
    .container,
    .home .main-content .container { width: min(100% - 40px, 720px); }
    .area-grid { grid-template-columns: repeat(2, 1fr); }
    .article-layout { grid-template-columns: minmax(0, 1fr) 180px; gap: 38px; }
}

@media (max-width: 700px) {
    .container,
    .home .main-content .container { width: calc(100% - 32px); }
    .site-header { height: 180px; padding-top: 20px; }
    .home .site-header { height: 78px; }
    .brand-mark { width: 36px; height: 36px; font-size: 31px; }
    .access-name { display: none; }
    .hero { height: 304px; padding-top: 58px; }
    .hero h1 { font-size: 26px; line-height: 32px; }
    .search-form, .page-search { height: 60px; padding: 0 18px; gap: 14px; }
    .search-form input { font-size: 16px; }
    .header-search .search-form { margin-top: 18px; }
    .home .main-content { padding: 30px 0 70px; }
    .area-grid { grid-template-columns: 1fr; gap: 18px; }
    .area-card { min-height: 190px; }
    .page-head { padding: 30px 0 24px; }
    .page-head .breadcrumbs { margin-bottom: 24px; }
    .page-head h1 { font-size: 25px; line-height: 30px; }
    .collection-card span { display: none; }
    .single-sante_pop .main-content { padding: 30px 0 70px; }
    .article-layout { grid-template-columns: 1fr; gap: 0; }
    .article-main .breadcrumbs { margin-bottom: 30px; }
    .article-main h1 { font-size: 29px; line-height: 35px; }
    .article-content { margin-top: 38px; }
    .article-toc { display: none; }
    .footer-inner { display: block; }
}

/* Ranking minimalista */
.ranking-modern {
    padding: 30px;
    border: 1px solid #e3e8f1;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 8px 28px rgba(25, 51, 100, .05);
}
.ranking-modern-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    padding-bottom: 24px;
}
.ranking-modern-header h2 {
    margin: 3px 0 6px;
    color: #1b2947;
    font-size: 26px;
    line-height: 1.2;
}
.ranking-modern-header p:not(.learning-kicker) { margin: 0; color: #6e7890; font-size: 14px; }
.ranking-participant-count {
    flex: 0 0 auto;
    padding: 8px 12px;
    border-radius: 999px;
    background: #f2f5fa;
    color: #58657d;
    font-size: 13px;
    font-weight: 700;
}
.ranking-modern-list { border-top: 1px solid #e8ecf3; }
.ranking-member {
    display: grid;
    grid-template-columns: 32px 52px minmax(0, 1fr) auto;
    align-items: center;
    gap: 14px;
    min-height: 88px;
    padding: 14px 0;
    border-bottom: 1px solid #e8ecf3;
}
.ranking-member:last-child { border-bottom: 0; }
.ranking-member-position { color: #8a95aa; font-size: 14px; font-weight: 800; text-align: center; }
.ranking-member-avatar {
    display: grid;
    width: 48px;
    height: 48px;
    overflow: hidden;
    place-items: center;
    border-radius: 50%;
    background: linear-gradient(145deg, #dce8ff, #9bb8ff);
    color: #2142e7;
    font-size: 15px;
    font-weight: 800;
}
.ranking-member-avatar img { width: 100%; height: 100%; object-fit: cover; }
.ranking-member-info { min-width: 0; }
.ranking-member-info h3 { margin: 0 0 3px; color: #1b2947; font-size: 16px; line-height: 1.25; }
.ranking-member-info p { margin: 0; overflow: hidden; color: #7a8498; font-size: 13px; white-space: nowrap; text-overflow: ellipsis; }
.ranking-member-score { min-width: 110px; text-align: right; }
.ranking-member-score strong { display: block; color: #1b2947; font-size: 14px; }
.ranking-stars { display: flex; justify-content: flex-end; gap: 2px; margin-bottom: 5px; color: #dfe4ec; font-size: 15px; letter-spacing: 0; }
.ranking-stars .is-filled { color: #f6b83f; }
@media (max-width: 700px) {
    .ranking-modern { padding: 22px 18px; }
    .ranking-modern-header { display: block; }
    .ranking-participant-count { display: inline-block; margin-top: 14px; }
    .ranking-member { grid-template-columns: 26px 44px minmax(0, 1fr); gap: 10px; }
    .ranking-member-avatar { width: 42px; height: 42px; }
    .ranking-member-score { grid-column: 3; min-width: 0; text-align: left; }
    .ranking-stars { justify-content: flex-start; }
}

.header-links {
    display: flex;
    gap: 12px;
    margin-right: 4px;
}
.header-links a {
    padding: 7px 10px;
    border-radius: 999px;
    border: 1px solid rgba(255,255,255,.28);
    color: #fff;
    font-size: 13px;
    line-height: 1;
}
.header-links a:hover { background: rgba(255,255,255,.12); }

.search-form { position: relative; }
.search-suggestions {
    position: absolute;
    z-index: 30;
    left: 0;
    right: 0;
    top: calc(100% + 10px);
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 14px;
    box-shadow: 0 16px 40px rgba(0,0,0,.12);
    padding: 10px;
}
.suggestion-title {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .12em;
    color: #829088;
    padding: 4px 8px 10px;
}
.search-suggestions ul {
    list-style: none;
    margin: 0;
    padding: 0;
}
.search-suggestions li + li { margin-top: 6px; }
.search-suggestions a {
    display: block;
    padding: 10px 12px;
    border-radius: 10px;
    color: var(--ink);
}
.search-suggestions a:hover { background: var(--soft); }
.search-suggestions strong {
    display: block;
    margin-bottom: 4px;
}
.search-suggestions span {
    display: block;
    font-size: 12px;
    line-height: 1.45;
    color: var(--muted);
}
.suggestion-empty {
    padding: 8px 12px 10px;
    color: var(--muted);
    font-size: 13px;
}

.learning-panel {
    margin-top: 48px;
    padding: 24px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow);
}
.learning-panel-head {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}
.learning-kicker {
    margin: 0 0 6px;
    color: var(--brand);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
}
.learning-panel h2 {
    margin: 0;
    font-size: 24px;
    line-height: 1.2;
}
.learning-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: end;
}
.learning-badges span {
    padding: 7px 10px;
    border-radius: 999px;
    background: var(--soft);
    color: var(--muted);
    font-size: 12px;
    font-weight: 700;
}
.learning-notice {
    margin: 0 0 18px;
    padding: 12px 14px;
    border-radius: 10px;
    background: #f5f5f5;
    color: var(--ink);
    font-size: 14px;
}
.learning-notice.concluido { background: #e9f7ef; color: #1f6d3b; }
.learning-progress {
    margin: 0 0 18px;
    padding: 12px 14px;
    border-radius: 10px;
    background: #f8f8f8;
    color: var(--muted);
    font-size: 13px;
}
.learning-quiz, .learning-complete {
    display: grid;
    gap: 14px;
}
.quiz-card {
    margin: 0;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
}
.quiz-card legend {
    padding: 0 8px;
    font-size: 15px;
    font-weight: 800;
    color: var(--ink);
}
.quiz-option {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 8px 0;
    color: var(--muted);
    font-size: 14px;
}
.quiz-option input { margin-top: 3px; }
.quiz-submit {
    justify-self: start;
    border: 0;
    border-radius: 10px;
    background: var(--brand);
    color: #fff;
    font-weight: 800;
    padding: 12px 18px;
    cursor: pointer;
}
.quiz-submit:hover { background: var(--brand-dark); }
.learning-certificate { margin-top: 18px; }

.learning-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}
.learning-summary-card {
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
}
.learning-summary-card strong {
    display: block;
    margin-bottom: 6px;
    font-size: 24px;
    color: var(--ink);
}
.learning-summary-card span {
    color: var(--muted);
    font-size: 13px;
}

.portal-locked {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 24px;
    background: linear-gradient(118deg, #0828c9 0%, #2142e7 100%);
}
.portal-locked-card {
    width: min(640px, 100%);
    padding: 28px;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 24px 60px rgba(0,0,0,.16);
}
.portal-locked-card h1 {
    margin: 0 0 12px;
    font-size: 34px;
    line-height: 1.15;
}
.portal-locked-meta {
    color: var(--muted);
    font-size: 13px;
}
.portal-locked-card .back-link {
    margin-left: 14px;
}

@media (max-width: 980px) {
    .header-links { display: none; }
    .learning-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 700px) {
    .learning-panel-head { display: block; }
    .learning-badges { justify-content: start; margin-top: 12px; }
    .learning-summary { grid-template-columns: 1fr; }
    .portal-locked-card { padding: 22px; }
}

.search-form {
    position: relative;
    align-items: center;
    gap: 14px;
    padding: 10px 12px 10px 22px;
    border-radius: 999px;
}
.search-form .search-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #1f67d2;
    flex: 0 0 auto;
}
.search-form input {
    flex: 1 1 auto;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    font-size: 18px;
    color: #1a2a4c;
}
.search-form input::placeholder { color: #7482a0; }
.search-form .search-clear {
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: #51607f;
    font-size: 30px;
    line-height: 1;
    cursor: pointer;
}
.search-form .search-submit {
    min-width: 176px;
    height: 54px;
    border-radius: 999px;
    background: #273db8;
    box-shadow: none;
    font-size: 17px;
    font-weight: 800;
}
.search-form .search-submit:hover { background: #1f2fa0; }
.search-form.page-search {
    max-width: 100%;
    margin: 18px 0 0;
    box-shadow: 0 8px 30px rgba(0,0,0,.08);
}

.search-suggestions {
    padding: 0;
    overflow: hidden;
    border: 0;
    border-radius: 18px;
    box-shadow: 0 22px 52px rgba(0,0,0,.16);
}
.suggestion-title {
    padding: 18px 24px 14px;
    color: #7e8aa9;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .1em;
}
.suggestion-list {
    list-style: none;
    margin: 0;
    padding: 0;
}
.suggestion-item {
    display: block;
    padding: 18px 24px 20px;
    border-top: 1px solid #d4dbe8;
    background: #fff;
}
.suggestion-item:hover { background: #f8fbff; }
.suggestion-kind {
    display: block;
    margin-bottom: 6px;
    color: #4a89d8;
    font-size: 14px;
    line-height: 1.1;
}
.suggestion-headline {
    display: block;
    color: #22304f;
    font-size: 18px;
    font-weight: 500;
    line-height: 1.35;
}
.suggestion-headline strong { color: #1f67d2; font-weight: 800; }
.suggestion-path,
.suggestion-excerpt {
    display: block;
    margin-top: 5px;
    color: #4e5971;
    font-size: 16px;
    line-height: 1.4;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.suggestion-excerpt { color: #6f788d; font-size: 14px; }
.suggestion-empty {
    padding: 18px 24px 20px;
    color: #60708f;
    font-size: 15px;
}

.search-result-grid {
    display: grid;
    gap: 14px;
}
.search-result-card {
    display: block;
    padding: 18px 20px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 12px 32px rgba(0,0,0,.04);
}
.search-result-card:hover {
    transform: translateY(-1px);
    box-shadow: 0 16px 40px rgba(0,0,0,.08);
}
.search-result-headline {
    display: flex;
    flex-direction: column;
    gap: 3px;
}
.search-result-section {
    color: #4a89d8;
    font-size: 16px;
    font-weight: 600;
}
.search-result-headline h2 {
    margin: 0;
    color: #22304f;
    font-size: 28px;
    font-weight: 500;
    line-height: 1.15;
    letter-spacing: -.6px;
}
.search-result-headline strong { color: #1f67d2; font-weight: 800; }
.search-result-path {
    margin: 8px 0 0;
    color: #4e5971;
    font-size: 15px;
    line-height: 1.5;
}
.search-result-excerpt {
    margin: 4px 0 0;
    color: #6b768d;
    font-size: 14px;
    line-height: 1.5;
}

.learning-dashboard { display: grid; gap: 18px; }
.learning-summary-card-identity .summary-label {
    display: block;
    margin-bottom: 8px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.learning-summary-card-identity strong { font-size: 22px; }
.empty-state-wide { padding: 28px; }
.learning-progress-panel { margin-top: 0; }
.learning-progress-table-wrap { overflow-x: auto; }
.learning-progress-table {
    width: 100%;
    border-collapse: collapse;
}
.learning-progress-table th,
.learning-progress-table td {
    padding: 16px 14px;
    border-top: 1px solid var(--line);
    vertical-align: top;
    text-align: left;
}
.learning-progress-table thead th {
    border-top: 0;
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.learning-progress-table td strong {
    display: block;
    color: var(--ink);
    font-size: 15px;
}
.learning-progress-table td span,
.learning-progress-table td small {
    display: block;
    color: var(--muted);
    font-size: 13px;
    margin-top: 4px;
}
.status-badge {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    background: #f0f4f7;
    color: #51606e;
    font-size: 12px;
    font-weight: 700;
}
.status-badge.is-done { background: #e9f7ef; color: #1f6d3b; }
.status-badge.is-pending { background: #eef3ff; color: #2740b8; }
.ranking-podium {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 16px;
}
.ranking-podium-card {
    padding: 18px;
    border-radius: 16px;
    background: linear-gradient(180deg, #f8fbff 0%, #ffffff 100%);
    border: 1px solid var(--line);
}
.ranking-podium-card strong {
    display: block;
    margin: 8px 0 4px;
    color: var(--ink);
    font-size: 18px;
}
.ranking-podium-card span,
.ranking-podium-card small { display: block; color: var(--muted); }
.ranking-position {
    display: inline-flex;
    align-items: center;
    padding: 5px 9px;
    border-radius: 999px;
    background: #2142e7;
    color: #fff;
    font-size: 12px;
    font-weight: 800;
}

@media (max-width: 980px) {
    .search-form .search-submit { min-width: 140px; }
    .ranking-podium { grid-template-columns: 1fr; }
}

@media (max-width: 700px) {
    .search-form {
        border-radius: 26px;
        gap: 10px;
        padding: 8px 12px 8px 18px;
    }
    .search-form input { font-size: 16px; }
    .search-form .search-submit {
        min-width: 120px;
        height: 46px;
        font-size: 15px;
    }
    .suggestion-headline { font-size: 16px; }
    .search-result-headline h2 { font-size: 22px; }
    .search-result-path { white-space: normal; }
    .search-result-excerpt { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
    .learning-progress-table th,
    .learning-progress-table td { padding: 12px 10px; }
}

/*
 * Busca e painel de aprendizagem — correção de UX.
 * Este bloco fica propositalmente no fim para substituir estilos legados
 * que ainda existiam no tema antes da busca com sugestões.
 */
body { font-size: 16px; }

.hero {
    height: auto;
    min-height: 356px;
    padding: 76px 0 88px;
    overflow: visible;
    z-index: 5;
}
.hero-inner { position: relative; }

.search-form,
.search-form.page-search {
    position: relative;
    width: 620px;
    max-width: 100%;
    height: 72px;
    margin: 0 auto;
    padding: 6px 7px 6px 28px;
    gap: 16px;
    border: 0;
    border-radius: 999px;
    background: #fff;
    box-shadow: 0 10px 28px rgba(0, 20, 100, .16);
}
.search-form .search-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    color: #1f67d2;
}
.search-form .search-icon svg { width: 27px; height: 27px; color: currentColor; }
.search-form input,
.search-form input[type="search"] {
    min-width: 0;
    height: 100%;
    color: #1b2a4b;
    font-size: 19px;
    line-height: 1;
    font-weight: 400;
    -webkit-appearance: none;
    appearance: none;
}
.search-form input::placeholder { color: #7180a0; }
.search-form input::-webkit-search-cancel-button,
.search-form input::-webkit-search-decoration { display: none; }
.search-form .search-clear {
    display: inline-grid;
    width: 36px;
    height: 36px;
    padding: 0;
    place-items: center;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: #4566a6;
    font-size: 30px;
    line-height: 1;
}
.search-form .search-clear[hidden] { display: none; }
.search-form .search-submit,
.search-form button.search-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    min-width: 136px;
    height: 60px;
    padding: 0 26px;
    border: 0;
    border-radius: 999px;
    background: #263cab;
    color: #fff;
    font-size: 17px;
    font-weight: 800;
    line-height: 1;
    text-shadow: none;
    cursor: pointer;
}
.search-form .search-submit:hover,
.search-form button.search-submit:hover { background: #1d2e92; }

.search-suggestions {
    position: absolute;
    z-index: 100;
    top: calc(100% + 8px);
    right: 0;
    left: 0;
    max-height: min(560px, calc(100vh - 150px));
    padding: 0;
    overflow: auto;
    border: 1px solid #d6dce8;
    border-radius: 9px;
    background: #fff;
    box-shadow: 0 20px 42px rgba(14, 31, 77, .22);
    text-align: left;
}
.suggestion-title {
    padding: 18px 28px 15px;
    color: #7383a6;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .1em;
    text-align: left;
}
.search-suggestions li + li { margin: 0; }
.suggestion-item {
    display: block;
    padding: 17px 28px 18px;
    border-top: 1px solid #d6dce8;
    border-radius: 0;
    background: #fff;
}
.suggestion-item:hover,
.suggestion-item:focus { background: #f6f9ff; }
.suggestion-kind,
.suggestion-excerpt { display: none !important; }
strong.suggestion-headline {
    display: block;
    color: #1f67c5;
    font-size: 18px;
    font-weight: 400;
    line-height: 1.3;
}
strong.suggestion-headline strong {
    display: inline;
    margin: 0;
    color: #1f67c5;
    font-weight: 800;
}
.suggestion-path {
    display: block;
    margin-top: 5px;
    overflow: hidden;
    color: #3f4755;
    font-size: 14px;
    line-height: 1.35;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.page-head { padding: 30px 0 18px; }
.page-head + .main-content { padding: 22px 0 82px; }
.page-content { margin-top: 0; }
.learning-dashboard { gap: 20px; }
.learning-summary { gap: 16px; }
.learning-summary-card {
    min-height: 122px;
    padding: 22px 20px;
    border-color: #e1e6ef;
    border-radius: 12px;
    box-shadow: 0 3px 10px rgba(20, 43, 92, .035);
}
.learning-summary-card strong { font-size: 28px; }
.learning-summary-card-identity strong {
    max-width: 100%;
    overflow-wrap: anywhere;
    word-break: break-word;
    font-size: clamp(16px, 1.25vw, 21px);
    line-height: 1.2;
}
.learning-progress-panel { border-color: #e1e6ef; }

@media (max-width: 700px) {
    .hero { min-height: 310px; padding: 55px 0 64px; }
    .hero h1 { font-size: 26px; line-height: 1.22; }
    .search-form,
    .search-form.page-search {
        height: 62px;
        padding: 5px 6px 5px 20px;
        gap: 10px;
    }
    .search-form .search-icon svg { width: 24px; height: 24px; }
    .search-form input,
    .search-form input[type="search"] { font-size: 16px; }
    .search-form .search-clear { width: 30px; height: 30px; font-size: 26px; }
    .search-form .search-submit,
    .search-form button.search-submit { min-width: 112px; height: 50px; padding: 0 16px; font-size: 15px; }
    .suggestion-item { padding: 15px 18px; }
    .suggestion-title { padding: 15px 18px 12px; }
    strong.suggestion-headline { font-size: 16px; }
    .suggestion-path { font-size: 13px; }
}
