/* APP AVAD — estilos (mobile-first). Paleta oficial aprovada. */
:root {
    --avad-deep: #051824;      /* base institucional */
    --avad-header: #0A3746;    /* cabeçalho escuro */
    --avad-structure: #135360; /* azul petróleo de estrutura */
    --avad-action: #0D939D;    /* turquesa de interação */
    --avad-accent: #D4A25A;    /* dourado de acento */
    --avad-bg: #F6F6F3;        /* fundo claro */
    --avad-support: #698E95;   /* azul acinzentado */
    --avad-neutral: #9BA5A8;   /* cinza neutro */
    --avad-white: #FFFFFF;

    --text: var(--avad-deep);
    --text-muted: #135360;
    --radius: 14px;
    --radius-sm: 10px;
    --shadow: 0 1px 2px rgba(5, 24, 36, .06), 0 6px 20px rgba(5, 24, 36, .06);
    --focus: 0 0 0 3px var(--avad-accent);
    --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
    margin: 0;
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.55;
    color: var(--text);
    background: var(--avad-bg);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}
img { max-width: 100%; height: auto; }
h1, h2, h3 { line-height: 1.25; margin: 0 0 .5rem; color: var(--avad-deep); }
h1 { font-size: 1.6rem; }
h2 { font-size: 1.2rem; }
.h3 { font-size: 1.05rem; margin-top: 1.5rem; }
p { margin: 0 0 1rem; }
a { color: var(--avad-structure); text-decoration-color: var(--avad-action); text-underline-offset: 3px; }
a:hover { color: var(--avad-header); }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: 6px; }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: 0; background: var(--avad-accent); color: var(--avad-deep); padding: .5rem 1rem; z-index: 100; }
.skip-link:focus { left: 1rem; top: 1rem; }
.muted { color: var(--text-muted); }
.small { font-size: .85rem; }

/* ---------- Cabeçalho ---------- */
.topbar { background: var(--avad-header); color: var(--avad-white); position: sticky; top: 0; z-index: 20; border-bottom: 3px solid var(--avad-structure); }
.topbar__inner { max-width: 1100px; margin: 0 auto; padding: .6rem 1rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.brand { display: inline-flex; align-items: center; gap: .6rem; color: var(--avad-white); text-decoration: none; font-weight: 700; letter-spacing: .04em; }
.brand:hover { color: var(--avad-white); }
.brand img { width: 40px; height: auto; }

.menu { position: relative; }
.menu__toggle { display: inline-flex; align-items: center; gap: .5rem; padding: .55rem .8rem; border-radius: var(--radius-sm); color: var(--avad-white); min-height: 44px; background: none; border: 1px solid rgba(255,255,255,.25); font: inherit; cursor: pointer; }
.menu__bars, .menu__bars::before, .menu__bars::after { display: block; width: 20px; height: 2px; background: var(--avad-white); border-radius: 2px; position: relative; }
.menu__bars::before, .menu__bars::after { content: ""; position: absolute; left: 0; }
.menu__bars::before { top: -6px; }
.menu__bars::after { top: 6px; }
.menu__panel {
    position: absolute; right: 0; top: calc(100% + .5rem); min-width: 220px;
    background: var(--avad-deep); border-radius: var(--radius); padding: .5rem; box-shadow: 0 10px 30px rgba(0,0,0,.3);
    display: none; flex-direction: column;
}
.menu.is-open .menu__panel { display: flex; }
.no-js .menu__toggle { display: none; }
.no-js .menu__panel { display: flex; position: static; flex-direction: row; flex-wrap: wrap; background: none; box-shadow: none; padding: 0; min-width: 0; }
.menu__panel a, .menu__panel .linklike {
    color: var(--avad-white); text-decoration: none; padding: .75rem .9rem; border-radius: var(--radius-sm);
    min-height: 44px; display: flex; align-items: center; font: inherit; text-align: left; width: 100%;
}
.menu__panel a:hover, .menu__panel .linklike:hover { background: var(--avad-structure); }
.menu__panel a[aria-current="page"] { box-shadow: inset 3px 0 0 var(--avad-accent); background: rgba(19, 83, 96, .5); }
.menu__logout { margin: 0; }
.menu__cta { border: 1px solid var(--avad-action); }
.linklike { background: none; border: 0; cursor: pointer; }

@media (min-width: 1100px) {
    .menu__toggle { display: none; }
    .menu__panel { display: flex; position: static; flex-direction: row; background: none; box-shadow: none; padding: 0; gap: .25rem; min-width: 0; }
    .menu__panel a, .menu__panel .linklike { width: auto; }
    .menu__panel a[aria-current="page"] { box-shadow: inset 0 -3px 0 var(--avad-accent); background: none; }
}

/* ---------- Estrutura ---------- */
.main { flex: 1; width: 100%; max-width: 1100px; margin: 0 auto; padding: 1.25rem 1rem 2.5rem; }
.main:focus { outline: none; }
.main--narrow { max-width: 640px; }
.footer { text-align: center; padding: 1.5rem 1rem; color: var(--avad-structure); font-size: .9rem; border-top: 1px solid rgba(155, 165, 168, .35); }
.footer p { margin: 0; }
.footer__muted { color: var(--avad-support); font-size: .8rem; }
.page-head { margin-bottom: 1.25rem; }
.stack > * + * { margin-top: 1rem; }
.note { margin-top: 1.5rem; font-size: .9rem; color: var(--text-muted); }

/* ---------- Cartões ---------- */
.card { background: var(--avad-white); border-radius: var(--radius); padding: 1.25rem; box-shadow: var(--shadow); border: 1px solid rgba(155, 165, 168, .25); }
.card--flush { padding: 0; overflow: hidden; }
.grid { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 640px) { .grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 980px) { .grid { grid-template-columns: repeat(3, 1fr); } }
.card--module { display: flex; flex-direction: column; border-top: 4px solid var(--avad-action); }
.card--module p { flex: 1; color: var(--avad-structure); }
.card--disabled { border-top-color: var(--avad-neutral); }
.card--brain { border-top-color: var(--avad-accent); }
.card__head { display: flex; justify-content: space-between; align-items: flex-start; gap: .5rem; }
.card__head h2 { font-size: 1.1rem; }
.card__link { font-weight: 600; align-self: flex-start; padding: .25rem 0; }

.badge { display: inline-block; font-size: .75rem; font-weight: 700; padding: .2rem .55rem; border-radius: 999px; white-space: nowrap; border: 1px solid transparent; }
.badge--ok { background: var(--avad-structure); color: var(--avad-white); }
.badge--wait { background: #FBF3E6; color: var(--avad-deep); border-color: var(--avad-accent); }
.badge--next { background: var(--avad-bg); color: var(--avad-structure); border-color: var(--avad-neutral); }

/* ---------- Boas-vindas ---------- */
.welcome { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.5rem; }
.welcome h1 { margin: 0; }
.welcome p { margin: 0; }

/* ---------- Botões ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
    min-height: 46px; padding: .7rem 1.25rem; border-radius: var(--radius-sm);
    font: inherit; font-weight: 700; text-decoration: none; cursor: pointer; border: 2px solid transparent;
    transition: background-color .15s, border-color .15s, color .15s;
}
.btn--primary { background: var(--avad-structure); color: var(--avad-white); border-color: var(--avad-structure); }
.btn--primary:hover { background: var(--avad-header); border-color: var(--avad-action); color: var(--avad-white); }
.btn--ghost { background: var(--avad-white); color: var(--avad-structure); border-color: var(--avad-action); }
.btn--ghost:hover { background: var(--avad-bg); color: var(--avad-header); }
.btn--danger-ghost { background: none; color: var(--avad-structure); border-color: var(--avad-neutral); }
.btn--danger-ghost:hover { border-color: var(--avad-deep); color: var(--avad-deep); }
.btn--block { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
.btn--file { position: relative; overflow: hidden; }
.btn--file input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; font-size: 100px; }
.btn--file:focus-within { box-shadow: var(--focus); }

/* ---------- Formulários ---------- */
.form .field { margin-bottom: 1rem; }
.field label { display: block; font-weight: 600; margin-bottom: .35rem; }
.field input[type=text], .field input[type=email], .field input[type=password], .field input[type=url], .field input[type=number], .field input[type=date], .field input:not([type]), .field select, .field textarea {
    width: 100%; min-height: 46px; padding: .65rem .8rem; font: inherit; color: var(--text);
    background: var(--avad-white); border: 1.5px solid var(--avad-neutral); border-radius: var(--radius-sm);
}
.field textarea { min-height: 96px; resize: vertical; line-height: 1.5; }
.field select:focus, .field textarea:focus { border-color: var(--avad-action); box-shadow: 0 0 0 3px rgba(13, 147, 157, .25); outline: none; }
.field input:focus { border-color: var(--avad-action); box-shadow: 0 0 0 3px rgba(13, 147, 157, .25); outline: none; }
.field input:disabled { background: var(--avad-bg); color: var(--avad-support); }
.field-row { display: flex; gap: .75rem; }
.field-row .field { flex: 1; }
.field--small { max-width: 110px; }
.hint { font-size: .85rem; color: var(--text-muted); margin: .35rem 0 0; }
.field-error { font-size: .88rem; color: var(--avad-deep); margin: .35rem 0 0; padding-left: .6rem; border-left: 3px solid var(--avad-accent); font-weight: 600; }
.check { display: flex; gap: .6rem; align-items: flex-start; margin: .5rem 0 1rem; cursor: pointer; }
.check input { width: 20px; height: 20px; margin-top: .15rem; accent-color: var(--avad-action); }
.password { display: flex; gap: .5rem; }
.password input { flex: 1; }
.password__toggle { min-width: 84px; background: var(--avad-bg); border: 1.5px solid var(--avad-neutral); border-radius: var(--radius-sm); font: inherit; font-size: .9rem; color: var(--avad-structure); cursor: pointer; }

/* ---------- Alertas ---------- */
.alert { border-radius: var(--radius-sm); padding: .8rem 1rem; margin-bottom: 1rem; border-left: 5px solid; background: var(--avad-white); box-shadow: var(--shadow); }
.alert--success { border-color: var(--avad-action); }
.alert--error { border-color: var(--avad-accent); background: #FBF3E6; }
.alert--info { border-color: var(--avad-support); }

/* ---------- Autenticação ---------- */
.auth { display: flex; justify-content: center; }
.auth__card { width: 100%; max-width: 440px; background: var(--avad-white); border-radius: var(--radius); padding: 1.5rem 1.25rem; box-shadow: var(--shadow); }
.auth__logo { display: block; margin: 0 auto 1rem; width: 240px; }
.auth__card h1 { text-align: center; }
.auth__links { text-align: center; margin: 1rem 0 .25rem; }
.auth__alt { text-align: center; margin: .75rem 0 0; color: var(--text-muted); }

/* ---------- Landing ---------- */
.hero { text-align: center; padding: 1rem 0 2rem; }
.hero__logo { width: min(520px, 100%); margin-bottom: 1rem; }
.hero__lead { font-size: 1.1rem; max-width: 620px; margin: 0 auto 1.5rem; color: var(--avad-structure); }
.hero__actions { display: flex; flex-direction: column; gap: .75rem; max-width: 360px; margin: 0 auto; }
.hero__note { margin-top: 1rem; }
@media (min-width: 560px) { .hero__actions { flex-direction: row; max-width: none; justify-content: center; } }
.features { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 760px) { .features { grid-template-columns: repeat(3, 1fr); } }
.feature { background: var(--avad-header); color: var(--avad-white); border-radius: var(--radius); padding: 1.25rem; border-bottom: 4px solid var(--avad-accent); }
.feature h2 { color: var(--avad-white); font-size: 1.1rem; }
.feature p { margin: 0; color: #E6EEEF; }

/* ---------- Avatar ---------- */
.avatar { display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; object-fit: cover; flex: 0 0 auto; font-weight: 700; color: var(--avad-white); letter-spacing: .02em; user-select: none; background: var(--avad-structure); }
.avatar--sm { width: 32px; height: 32px; font-size: .8rem; }
.avatar--md { width: 44px; height: 44px; font-size: 1rem; }
.avatar--lg { width: 64px; height: 64px; font-size: 1.35rem; }
.avatar--xl { width: 120px; height: 120px; font-size: 2.4rem; }
.avatar--c1 { background: var(--avad-structure); }
.avatar--c2 { background: var(--avad-header); }
.avatar--c3 { background: var(--avad-deep); color: var(--avad-accent); }
.avatar--c4 { background: var(--avad-accent); color: var(--avad-deep); }
img.avatar { border: 3px solid var(--avad-white); box-shadow: 0 0 0 2px var(--avad-action); }

/* ---------- Foto de perfil / recorte ---------- */
.photo { display: flex; flex-direction: column; align-items: center; gap: 1rem; text-align: center; }
.photo__actions { display: flex; flex-direction: column; gap: .5rem; align-items: center; }
.photo__actions form { margin: 0; }
@media (min-width: 640px) {
    .photo { flex-direction: row; align-items: flex-start; text-align: left; }
    .photo__actions { align-items: flex-start; }
}
.cropper { margin-top: 1.25rem; border-top: 1px solid rgba(155,165,168,.35); padding-top: 1rem; }
.cropper[hidden] { display: none; }
.cropper__hint { font-size: .9rem; color: var(--text-muted); }
.cropper__stage { display: flex; justify-content: center; }
.cropper__stage canvas { width: min(320px, 100%); height: auto; aspect-ratio: 1; border-radius: 50%; background: var(--avad-bg); cursor: grab; touch-action: none; box-shadow: 0 0 0 3px var(--avad-action); }
.cropper__stage canvas:active { cursor: grabbing; }
.cropper__zoom { display: flex; align-items: center; gap: .75rem; max-width: 320px; margin: 1rem auto; }
.cropper__zoom input { flex: 1; accent-color: var(--avad-action); min-height: 44px; }
.cropper__buttons { display: flex; gap: .75rem; justify-content: center; }

/* ---------- Listas, tabelas ---------- */
.list { list-style: none; margin: 0; padding: 0; }
.list__item { display: flex; justify-content: space-between; align-items: center; gap: .75rem; padding: .8rem 0; border-bottom: 1px solid rgba(155,165,168,.3); flex-wrap: wrap; }
.list__item:last-child { border-bottom: 0; }
.kv { display: grid; grid-template-columns: 1fr; gap: .15rem .75rem; margin: 0 0 1rem; }
.kv dt { font-weight: 600; color: var(--avad-structure); font-size: .85rem; margin-top: .5rem; }
.kv dd { margin: 0; }
@media (min-width: 560px) { .kv { grid-template-columns: 200px 1fr; } .kv dt { margin-top: 0; } }

.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.table th { text-align: left; background: var(--avad-header); color: var(--avad-white); padding: .7rem .8rem; font-weight: 600; }
.table td { padding: .65rem .8rem; border-bottom: 1px solid rgba(155,165,168,.3); vertical-align: top; }
@media (max-width: 700px) {
    .table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
    .table tr { display: block; border-bottom: 2px solid rgba(155,165,168,.4); padding: .5rem 0; }
    .table td { display: flex; justify-content: space-between; gap: 1rem; border: 0; padding: .3rem .9rem; text-align: right; }
    .table td::before { content: attr(data-label); font-weight: 600; color: var(--avad-structure); text-align: left; }
}
.pager { display: flex; justify-content: space-between; align-items: center; gap: .5rem; margin-top: 1rem; flex-wrap: wrap; }

/* ---------- Instalador ---------- */
.page-plain .plain-logo { text-align: center; margin: .5rem 0 1rem; }
.page-plain .plain-logo img { width: 280px; }
.checks { list-style: none; padding: 0; margin: 0 0 1rem; }
.checks__item { display: flex; gap: .6rem; align-items: center; padding: .35rem 0; font-size: .95rem; }
.checks__icon { width: 24px; height: 24px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-weight: 700; font-size: .8rem; flex: 0 0 auto; }
.checks__item--ok .checks__icon { background: var(--avad-structure); color: var(--avad-white); }
.checks__item--fail .checks__icon { background: var(--avad-deep); color: var(--avad-accent); }
.checks__item--warn .checks__icon { background: var(--avad-accent); color: var(--avad-deep); }

/* ---------- Erro ---------- */
.error-page { text-align: center; padding: 2rem 0; max-width: 560px; margin: 0 auto; }
.error-page__code { font-size: 3.5rem; font-weight: 800; color: var(--avad-action); margin: 0; line-height: 1; }
.actions { margin-top: 1.5rem; }

/* ---------- Abas (Brain AVAD, Minhas anotações) ---------- */
.tabs { display: flex; gap: .25rem; margin: 0 0 1.25rem; box-shadow: inset 0 -2px 0 rgba(155,165,168,.35); overflow-x: auto; overflow-y: hidden; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs a { padding: .65rem 1rem; text-decoration: none; font-weight: 600; color: var(--avad-structure); border-bottom: 3px solid transparent; white-space: nowrap; min-height: 44px; display: inline-flex; align-items: center; }
.tabs a[aria-current="page"] { color: var(--avad-deep); border-bottom-color: var(--avad-accent); }
.inline-form { display: inline-block; margin: .5rem .5rem 0 0; }
code { font-size: .88em; background: var(--avad-bg); padding: .1rem .35rem; border-radius: 6px; word-break: break-all; }

/* ---------- Bíblia: leitor ---------- */
.page-reader .main { max-width: 760px; padding-bottom: 7rem; }
.page-reader .topbar { position: static; }
.reader-bar {
    position: sticky; top: .5rem; z-index: 15; display: flex; align-items: center; gap: .4rem;
    background: var(--avad-white); border: 1px solid rgba(155,165,168,.35); border-radius: var(--radius);
    padding: .35rem; box-shadow: var(--shadow); margin-bottom: 1rem;
}
.reader-bar__step { flex: 0 0 auto; width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center; font-size: 1.6rem; line-height: 1; text-decoration: none; color: var(--avad-structure); border-radius: var(--radius-sm); }
.reader-bar__step:hover { background: var(--avad-bg); }
.reader-bar__step.is-disabled { color: var(--avad-neutral); }
.reader-bar__ref { flex: 1 1 auto; min-width: 0; min-height: 44px; display: inline-flex; align-items: center; justify-content: center; gap: .35rem; font-weight: 700; text-decoration: none; color: var(--avad-deep); border-radius: var(--radius-sm); padding: 0 .5rem; }
.reader-bar__ref span:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.reader-bar__ref:hover { background: var(--avad-bg); color: var(--avad-deep); }
.reader-bar__caret { color: var(--avad-action); font-size: .8rem; }
.reader-bar__version { display: flex; gap: .25rem; margin: 0; }
.reader-bar__version select { min-height: 44px; border: 1.5px solid var(--avad-neutral); border-radius: var(--radius-sm); background: var(--avad-bg); font: inherit; font-weight: 700; color: var(--avad-structure); padding: 0 .4rem; max-width: 96px; }
.reader-bar__go { min-height: 44px; border: 0; border-radius: var(--radius-sm); background: var(--avad-structure); color: var(--avad-white); font: inherit; padding: 0 .7rem; cursor: pointer; }
html:not(.no-js) .reader-bar__go { display: none; }
.reader-bar__font { display: none; }
@media (min-width: 560px) {
    .reader-bar__font:not([hidden]) { display: flex; gap: .15rem; }
    .reader-bar__font button { min-width: 40px; min-height: 44px; border: 0; background: none; color: var(--avad-structure); font: inherit; font-weight: 700; cursor: pointer; border-radius: var(--radius-sm); }
    .reader-bar__font button:hover { background: var(--avad-bg); }
}

.scripture { --scripture-size: 1.15rem; background: var(--avad-white); border-radius: var(--radius); padding: 1.5rem 1.15rem; box-shadow: var(--shadow); border: 1px solid rgba(155,165,168,.25); }
.scripture__title { font-size: 1.5rem; text-align: center; margin: 0; font-weight: 700; }
.scripture__title span { color: var(--avad-action); }
.scripture__version { text-align: center; font-size: .82rem; color: var(--avad-support); margin: .2rem 0 1.25rem; letter-spacing: .02em; }
.scripture__text { font-family: Georgia, "Times New Roman", serif; font-size: var(--scripture-size); line-height: 1.8; color: var(--avad-deep); }
.v { display: block; padding: .15rem .35rem; margin: 0 -.35rem; border-radius: 6px; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.v:hover { background: rgba(13, 147, 157, .06); }
.v__n { font-family: var(--font); font-size: .62em; font-weight: 700; color: var(--avad-action); margin-right: .3rem; vertical-align: super; line-height: 0; }
.v.is-fav { background: linear-gradient(transparent 62%, rgba(212, 162, 90, .35) 62%); }
.v.is-selected { background: rgba(13, 147, 157, .16); box-shadow: inset 3px 0 0 var(--avad-action); }
.v__note { font-family: var(--font); font-size: .75em; color: var(--avad-accent); margin-left: .25rem; }
:target.v { background: rgba(212, 162, 90, .2); }
.scripture__text--html p, .scripture__text--html > div { margin: 0 0 .9rem; }
.scripture__text--html .yv-h, .scripture__text--html .yv-s1, .scripture__text--html .yv-s2, .scripture__text--html .s1, .scripture__text--html .s2, .scripture__text--html .heading {
    font-family: var(--font); font-size: 1rem; font-weight: 700; color: var(--avad-structure); margin: 1.4rem 0 .4rem; line-height: 1.4;
}
.scripture__text--html h3, .scripture__text--html h4 { font-family: var(--font); font-size: 1rem; color: var(--avad-structure); margin: 1.2rem 0 .4rem; }
.scripture__text--html sup, .scripture__text--html .label, .scripture__text--html .vlbl, .scripture__text--html .yv-vlbl { font-family: var(--font); font-size: .62em; font-weight: 700; color: var(--avad-action); margin-right: .2rem; }
.vseg { cursor: pointer; border-radius: 3px; -webkit-tap-highlight-color: transparent; }
.vseg:hover { background: rgba(13, 147, 157, .06); }
.vseg.is-fav { background: linear-gradient(transparent 62%, rgba(212, 162, 90, .35) 62%); }
.vseg.is-selected { background: rgba(13, 147, 157, .18); }

.reader-pager { display: flex; justify-content: space-between; gap: .75rem; margin: 1.25rem 0; flex-wrap: wrap; }
.reader-pager .btn { flex: 1 1 auto; }
.reader-credit { font-size: .8rem; color: var(--avad-support); text-align: center; }
.reader-credit p { margin: 0 0 .4rem; }

/* Barra de áudio */
.audio-bar {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: flex; align-items: center; gap: .75rem;
    background: var(--avad-header); color: var(--avad-white); padding: .6rem max(1rem, env(safe-area-inset-left)) calc(.6rem + env(safe-area-inset-bottom));
    border-top: 3px solid var(--avad-accent);
}
.audio-bar__play { flex: 0 0 auto; width: 52px; height: 52px; border-radius: 50%; border: 0; background: var(--avad-action); color: var(--avad-white); font-size: 1.3rem; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.audio-bar__play:hover { background: var(--avad-structure); box-shadow: 0 0 0 2px var(--avad-action); }
.audio-bar__body { flex: 1; min-width: 0; }
.audio-bar__title { margin: 0; font-weight: 700; font-size: .92rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.audio-bar__seek { width: 100%; accent-color: var(--avad-accent); margin: .15rem 0; min-height: 24px; }
.audio-bar__meta { margin: 0; font-size: .78rem; color: #CFE0E2; font-variant-numeric: tabular-nums; }
.audio-bar__status { margin-left: .4rem; color: var(--avad-accent); }
.audio-bar__auto { display: flex; flex-direction: column; align-items: center; font-size: .72rem; gap: .1rem; cursor: pointer; }
.audio-bar__auto input { width: 20px; height: 20px; accent-color: var(--avad-accent); }
@media (min-width: 760px) { .audio-bar { left: 50%; right: auto; transform: translateX(-50%); width: min(760px, 100% - 2rem); bottom: 1rem; border-radius: var(--radius); border-top: 0; box-shadow: 0 10px 30px rgba(5,24,36,.35); padding: .6rem 1rem; } }

/* Painel de ações do versículo */
.verse-sheet {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; background: var(--avad-white);
    border-radius: var(--radius) var(--radius) 0 0; box-shadow: 0 -10px 30px rgba(5,24,36,.25);
    padding: 1rem 1rem calc(1rem + env(safe-area-inset-bottom)); border-top: 4px solid var(--avad-action);
    max-height: 85vh; overflow-y: auto;
}
.verse-sheet[hidden] { display: none; }
@media (min-width: 760px) { .verse-sheet { left: 50%; right: auto; width: 560px; transform: translateX(-50%); bottom: 1rem; border-radius: var(--radius); } }
.verse-sheet__head { display: flex; justify-content: space-between; align-items: center; margin-bottom: .75rem; }
.verse-sheet__close { width: 44px; height: 44px; border: 0; background: var(--avad-bg); border-radius: 50%; cursor: pointer; font-size: 1rem; color: var(--avad-structure); }
.verse-sheet__actions { display: flex; flex-wrap: wrap; gap: .5rem; }
.verse-sheet__actions .btn { flex: 1 1 auto; min-height: 44px; padding: .5rem .9rem; }
.verse-sheet__note { margin-top: 1rem; }
.verse-sheet__note[hidden] { display: none; }
.verse-sheet__note label { display: block; font-weight: 600; margin-bottom: .35rem; font-size: .9rem; }
.verse-sheet__note textarea { width: 100%; min-height: 110px; padding: .65rem .8rem; font: inherit; border: 1.5px solid var(--avad-neutral); border-radius: var(--radius-sm); resize: vertical; }
.verse-sheet__note textarea:focus { border-color: var(--avad-action); outline: none; box-shadow: 0 0 0 3px rgba(13,147,157,.25); }
.verse-sheet__note-actions { display: flex; gap: .5rem; margin-top: .6rem; flex-wrap: wrap; }
.verse-sheet__msg { margin: .6rem 0 0; font-size: .88rem; color: var(--avad-structure); min-height: 1.2em; }

/* Seletor de livros */
.books-dialog { width: min(680px, 100% - 1.5rem); max-height: 86vh; padding: 0; border: 0; border-radius: var(--radius); box-shadow: 0 20px 50px rgba(5,24,36,.4); color: var(--text); }
.books-dialog::backdrop { background: rgba(5, 24, 36, .55); }
.books-dialog__head { display: flex; align-items: center; justify-content: space-between; padding: .9rem 1rem; background: var(--avad-header); color: var(--avad-white); position: sticky; top: 0; z-index: 1; }
.books-dialog__head h2 { color: var(--avad-white); margin: 0; font-size: 1.1rem; }
.books-dialog__tabs { display: flex; position: sticky; top: 62px; background: var(--avad-white); z-index: 1; border-bottom: 2px solid rgba(155,165,168,.35); }
.books-dialog__tabs button { flex: 1; min-height: 46px; border: 0; background: none; font: inherit; font-weight: 600; color: var(--avad-structure); cursor: pointer; border-bottom: 3px solid transparent; margin-bottom: -2px; }
.books-dialog__tabs button[aria-selected="true"] { color: var(--avad-deep); border-bottom-color: var(--avad-accent); }
.books-dialog__tabs[hidden] { display: none; }
.books-dialog__body { padding: 1rem; }
.book-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: .4rem; }
@media (min-width: 520px) { .book-grid { grid-template-columns: repeat(3, 1fr); } }
.book-grid a, .book-grid button { display: flex; align-items: center; min-height: 46px; padding: .4rem .75rem; border-radius: var(--radius-sm); background: var(--avad-bg); color: var(--avad-deep); text-decoration: none; border: 1px solid transparent; font: inherit; text-align: left; cursor: pointer; }
.book-grid a:hover, .book-grid button:hover, .book-grid .is-current { border-color: var(--avad-action); background: #EAF4F5; }
.chapter-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(52px, 1fr)); gap: .4rem; }
.chapter-grid a { display: flex; align-items: center; justify-content: center; min-height: 48px; border-radius: var(--radius-sm); background: var(--avad-bg); color: var(--avad-deep); text-decoration: none; font-weight: 600; border: 1px solid transparent; }
.chapter-grid a:hover, .chapter-grid a.is-current { border-color: var(--avad-action); background: #EAF4F5; }
.chapter-back { margin-bottom: .75rem; border: 0; background: none; color: var(--avad-structure); font: inherit; font-weight: 600; cursor: pointer; min-height: 44px; padding: 0; }
.book-section + .book-section { margin-top: 1rem; }

/* Traduções e anotações */
.version-list__item { padding: 1rem 1.25rem; align-items: flex-start; }
.version-list__main { flex: 1 1 320px; min-width: 0; }
.version-list__main p { margin: 0 0 .3rem; }
.version-list__side { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; }
.note-card__ref { font-size: 1.05rem; }
.note-card__verse { font-family: Georgia, "Times New Roman", serif; font-size: 1.05rem; line-height: 1.7; border-left: 3px solid var(--avad-accent); padding-left: .8rem; }
.provider-status .checks { margin-bottom: .5rem; }
.catalog-form { margin-bottom: 1rem; }

/* ---------- Menu: avisos ---------- */
.menu__badge { display: inline-flex; align-items: center; justify-content: center; min-width: 20px; height: 20px; padding: 0 6px; margin-left: .3rem; border-radius: 999px; background: var(--avad-accent); color: var(--avad-deep); font-size: .75rem; font-weight: 800; }
@media (min-width: 1100px) { .menu__panel a, .menu__panel .linklike { padding: .75rem .7rem; } }
/* Sino de avisos: ícone no item do menu e atalho compacto ao lado do botão Menu (telas < 1100 px) */
.menu { display: flex; align-items: center; gap: .5rem; }
.bell-icon { flex: 0 0 auto; }
.menu__bell .bell-icon { margin-right: .45rem; }
.bell { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: var(--radius-sm); color: var(--avad-white); border: 1px solid rgba(255,255,255,.25); text-decoration: none; }
.bell:hover { color: var(--avad-white); background: var(--avad-structure); }
.bell:focus-visible { outline: none; box-shadow: var(--focus); }
.bell[aria-current="page"] { border-color: var(--avad-accent); }
.bell .bell-icon { width: 22px; height: 22px; }
.bell.has-unread .bell-icon { color: var(--avad-accent); }
.bell__badge { position: absolute; top: -6px; right: -6px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 999px; display: inline-flex; align-items: center; justify-content: center; background: var(--avad-accent); color: var(--avad-deep); font-size: .72rem; font-weight: 800; line-height: 1; border: 2px solid var(--avad-header); }
.no-js .bell { display: none; }
@media (min-width: 1100px) { .bell { display: none; } }
@media (max-width: 359px) { .topbar__inner { gap: .5rem; } .brand__text { white-space: nowrap; } .menu { gap: .35rem; } .bell { width: 40px; } .menu__toggle { padding: .55rem .6rem; } }

/* ---------- Planos e Grupos de Leitura (Fase 3) ---------- */
.main .linklike { font: inherit; font-weight: 600; color: var(--avad-structure); text-decoration: underline; text-decoration-color: var(--avad-action); text-underline-offset: 3px; min-height: 44px; padding: .25rem 0; }
.main .linklike:hover { color: var(--avad-header); }
.page-head--row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: 1rem; }
.page-head--row > div { flex: 1 1 320px; }
.actions-row { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; margin-top: .75rem; }
.actions-row .inline-form { margin: 0; }
.btn--sm { min-height: 40px; padding: .4rem .8rem; font-size: .9rem; }
.grow { flex: 1 1 auto; min-width: 0; }
.list__item--block { display: block; }
.person { display: flex; align-items: center; gap: .6rem; }
.chips { display: flex; flex-wrap: wrap; gap: .4rem; margin: 0 0 1.25rem; }
.chips a { display: inline-flex; align-items: center; gap: .35rem; min-height: 40px; padding: .35rem .9rem; border-radius: 999px; background: var(--avad-white); border: 1.5px solid rgba(155,165,168,.6); color: var(--avad-structure); text-decoration: none; font-weight: 600; font-size: .92rem; }
.chips a:hover { border-color: var(--avad-action); }
.chips a[aria-current="page"] { background: var(--avad-structure); border-color: var(--avad-structure); color: var(--avad-white); }
.chips__n { font-size: .75rem; opacity: .8; }
.plan-card h2 { font-size: 1.1rem; margin: .6rem 0 .4rem; }
.plan-card h2 a { text-decoration: none; color: var(--avad-deep); }
.plan-card h2 a:hover { color: var(--avad-structure); text-decoration: underline; }
.progress { -webkit-appearance: none; appearance: none; width: 100%; height: 10px; border: 0; border-radius: 999px; background: var(--avad-bg); overflow: hidden; display: block; margin: .4rem 0; }
.progress::-webkit-progress-bar { background: var(--avad-bg); border-radius: 999px; }
.progress::-webkit-progress-value { background: var(--avad-action); border-radius: 999px; }
.progress::-moz-progress-bar { background: var(--avad-action); border-radius: 999px; }
.day-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(46px, 1fr)); gap: .35rem; }
.day-grid a { display: flex; align-items: center; justify-content: center; min-height: 44px; border-radius: var(--radius-sm); background: var(--avad-bg); color: var(--avad-deep); text-decoration: none; font-weight: 600; font-size: .9rem; border: 1.5px solid transparent; }
.day-grid a:hover { border-color: var(--avad-action); }
.day-grid a.is-done { background: var(--avad-structure); color: var(--avad-white); }
.day-grid a.is-missing { background: var(--avad-white); border: 1.5px dashed var(--avad-neutral); color: var(--avad-support); }
.day-grid a.is-current { border-color: var(--avad-accent); box-shadow: 0 0 0 2px var(--avad-accent); }
.main > .card + .card, .main > .card + section, .main > .card + form, .main > .card + article, .main > .card + div, .main > div + .card, .main > .day-nav + .card, .main > .card + .chips, .main > .chips + .card { margin-top: 1rem; }
.devotional__text { font-family: Georgia, "Times New Roman", serif; font-size: 1.08rem; line-height: 1.8; }
.passages .passage + .passage { border-top: 1px solid rgba(155,165,168,.3); margin-top: 1rem; padding-top: 1rem; }
.passage__ref { font-size: 1rem; color: var(--avad-structure); margin: 0 0 .5rem; }
.passage__text { font-family: Georgia, "Times New Roman", serif; font-size: 1.05rem; line-height: 1.75; margin-bottom: .5rem; }
.passage__text .v { display: inline; padding: 0; margin: 0; cursor: auto; }
.passage__text .v:hover { background: none; }
.interaction { border-left: 5px solid var(--avad-accent); }
.day-nav { display: flex; justify-content: space-between; align-items: center; gap: .5rem; flex-wrap: wrap; margin: 1.25rem 0; }
.day-nav .inline-form { margin: 0; }
.comment-list { list-style: none; margin: 0 0 1rem; padding: 0; }
.comment { display: flex; gap: .75rem; padding: .9rem 0; border-bottom: 1px solid rgba(155,165,168,.3); }
.comment:last-child { border-bottom: 0; }
.comment__body { flex: 1; min-width: 0; }
.comment__meta { margin: 0 0 .25rem; display: flex; flex-wrap: wrap; gap: .5rem; align-items: baseline; }
.comment__text { margin: 0 0 .4rem; overflow-wrap: anywhere; }
.comment__hidden { margin: 0 0 .4rem; font-style: italic; color: var(--avad-support); }
.comment.is-hidden { opacity: .85; }
.comment__actions { display: flex; flex-wrap: wrap; gap: .75rem; align-items: flex-start; font-size: .9rem; }
.comment__actions .linklike, .comment__edit summary { color: var(--avad-structure); font-weight: 600; cursor: pointer; padding: .25rem 0; min-height: 32px; font: inherit; font-size: .9rem; }
.comment__actions .inline-form { margin: 0; }
.comment__edit { flex: 1 1 100%; }
.comment__edit:not([open]) { flex: 0 0 auto; }
.comment__edit form { margin-top: .5rem; display: flex; flex-direction: column; gap: .5rem; }
.comment__edit textarea, .comment__edit input[type=text], .comment-form textarea, .invite-link input, .theme-row input[type=text], .theme-row input[type=number], .report-box input[type=text] {
    width: 100%; padding: .55rem .7rem; font: inherit; border: 1.5px solid var(--avad-neutral); border-radius: var(--radius-sm); background: var(--avad-white); color: var(--text);
}
.comment-form { border-top: 1px solid rgba(155,165,168,.3); padding-top: 1rem; }
.invite-link { display: flex; gap: .4rem; flex-wrap: wrap; align-items: center; }
.invite-link input { flex: 1 1 260px; font-size: .85rem; min-height: 40px; }
.invite-meta { display: flex; justify-content: space-between; gap: .5rem; flex-wrap: wrap; margin-top: .4rem; align-items: center; }
.invite-meta .inline-form { margin: 0; }
.theme-row { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; width: 100%; margin: 0; }
.theme-row input[type=text] { flex: 1 1 200px; width: auto; min-height: 42px; }
.theme-row input[type=number] { width: 90px; min-height: 42px; }
.theme-row .check { margin: 0; }
.decision-msg { background: var(--avad-bg); border-left: 3px solid var(--avad-accent); padding: .6rem .8rem; border-radius: 6px; margin: .3rem 0 0; }
.decision-box { border-top: 4px solid var(--avad-accent); }
.report__snapshot { margin: .5rem 0; padding: .7rem .9rem; background: var(--avad-bg); border-left: 3px solid var(--avad-support); border-radius: 6px; overflow-wrap: anywhere; }
.report-box { margin-top: 1.5rem; font-size: .92rem; }
.report-box summary { cursor: pointer; color: var(--avad-structure); font-weight: 600; min-height: 40px; }
.report-box form { margin-top: .5rem; }
details > summary { cursor: pointer; }

/* ---------- Igrejas e escalas (Fase 4) ---------- */
.church-crumb { margin-bottom: .25rem; }
.church-title { margin-bottom: .75rem; }
.h1-like { font-size: 1.4rem; margin: 0 0 .25rem; }
.row-actions { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; }
.row-actions .inline-form { margin: 0; }
.member-row__head { display: flex; justify-content: space-between; align-items: center; gap: .75rem; flex-wrap: wrap; }
.quals { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem .9rem; margin-top: .6rem; padding: .6rem .75rem; background: var(--avad-bg); border-radius: var(--radius-sm); }
.check--inline { margin: 0; align-items: center; }
.chip { display: inline-flex; align-items: center; min-height: 34px; padding: .25rem .8rem; border-radius: 999px; background: var(--avad-bg); border: 1px solid rgba(155,165,168,.6); font-weight: 600; font-size: .9rem; color: var(--avad-structure); }
.invite-new { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; margin-top: .75rem; }
.invite-new select, .invite-new input[type=text], .convoke select { min-height: 42px; padding: .4rem .6rem; font: inherit; border: 1.5px solid var(--avad-neutral); border-radius: var(--radius-sm); background: var(--avad-white); color: var(--text); }
.invite-new input[type=text] { flex: 1 1 220px; }
.add-person { border-top: 1px solid rgba(155,165,168,.3); margin-top: 1rem; padding-top: 1rem; }
.new-event summary { cursor: pointer; min-height: 40px; }
.new-event form { margin-top: 1rem; }
.slot__title { font-size: 1.1rem; margin: 0; }
.slot__badges { display: flex; flex-wrap: wrap; gap: .3rem; justify-content: flex-end; }
.slot .list__item.is-past { opacity: .6; }
.slot__manage { border-top: 1px solid rgba(155,165,168,.3); margin-top: .5rem; padding-top: .75rem; display: flex; flex-direction: column; gap: .5rem; }
.convoke__row { display: flex; gap: .5rem; flex-wrap: wrap; }
.convoke__row select { flex: 1 1 220px; }
.people-strip { display: flex; flex-wrap: wrap; gap: .25rem; }
.people-strip__item.is-unavailable { opacity: .35; filter: grayscale(1); }
.card--attention { border-left: 5px solid var(--avad-accent); }
.agenda-item { align-items: flex-start; }
.notif__link { display: flex; flex-direction: column; gap: .15rem; text-decoration: none; color: var(--avad-deep); padding: .9rem 1.25rem; width: 100%; }
.notif__link:hover { background: var(--avad-bg); }
.notif-list .list__item { padding: 0; }
.notif.is-unread .notif__link { border-left: 4px solid var(--avad-accent); background: #FDFAF4; }
.notif__body { color: var(--avad-structure); font-size: .92rem; }
.promo { margin-top: 1.5rem; padding: 1rem 1.25rem; border-radius: var(--radius); background: var(--avad-white); border: 1px dashed var(--avad-support); font-size: .92rem; }
.promo p { margin: 0 0 .4rem; }

/* ---------- Louvor (Fase 5) ---------- */
.louvor-nav { margin-top: -.5rem; }
.field-row--wrap { flex-wrap: wrap; }
.field-row--wrap .field { flex: 1 1 220px; }
.field-row--wrap .field--key { flex: 0 1 140px; }
.field-row--wrap .field--label { flex: 0 1 160px; }
.link-fields { border: 0; padding: 0; margin: 0 0 1rem; }
.link-fields legend { font-weight: 600; margin-bottom: .35rem; padding: 0; }
.link-fields .field { margin-bottom: .5rem; }
.search-row { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.search-row input[type=search] { flex: 1 1 220px; min-height: 44px; padding: .5rem .7rem; font: inherit; border: 1.5px solid var(--avad-neutral); border-radius: var(--radius-sm); background: var(--avad-white); color: var(--text); }
.search-row input[type=search]:focus { border-color: var(--avad-action); box-shadow: 0 0 0 3px rgba(13, 147, 157, .25); outline: none; }
.key-badge { display: inline-flex; align-items: center; justify-content: center; min-width: 2.6rem; min-height: 2rem; padding: .1rem .55rem; border-radius: var(--radius-sm); background: var(--avad-bg); border: 1.5px solid var(--avad-support); color: var(--avad-deep); font-weight: 800; font-size: .95rem; letter-spacing: .02em; }
.key-badge--event { background: var(--avad-structure); border-color: var(--avad-structure); color: var(--avad-white); }
.link-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .4rem; }
.link-list a { font-weight: 600; }
.band-members { list-style: none; margin: 0; padding: 0; }
.band-member { display: flex; justify-content: space-between; align-items: center; gap: .6rem; flex-wrap: wrap; padding: .6rem 0; border-bottom: 1px solid rgba(155,165,168,.3); }
.band-member:last-child { border-bottom: 0; }
.band.is-inactive { opacity: .75; }
.band__edit { margin-top: .75rem; }
.band__edit summary { color: var(--avad-structure); font-weight: 600; min-height: 40px; display: flex; align-items: center; }
.setlist { list-style: none; margin: 0; padding: 0; counter-reset: none; }
.setlist__item { display: grid; grid-template-columns: 2.2rem 1fr auto; gap: .35rem .75rem; align-items: start; padding: .85rem 0; border-bottom: 1px solid rgba(155,165,168,.3); }
.setlist__item:last-child { border-bottom: 0; }
.setlist__pos { display: inline-flex; align-items: center; justify-content: center; width: 2rem; height: 2rem; border-radius: 50%; background: var(--avad-header); color: var(--avad-white); font-weight: 700; font-size: .9rem; }
.setlist__main { min-width: 0; overflow-wrap: anywhere; }
.setlist__links { margin: .3rem 0 0; display: flex; flex-wrap: wrap; gap: .25rem .8rem; }
.setlist__keys { display: flex; flex-direction: column; align-items: center; gap: .1rem; text-align: center; }
.setlist__tools { grid-column: 2 / -1; display: flex; flex-wrap: wrap; gap: .4rem .6rem; align-items: center; }
.setlist__tools .inline-form { margin: 0; }
.key-form { display: flex; gap: .35rem; align-items: center; }
.key-form select, .invite-new select, .role-form select { min-height: 40px; padding: .35rem .5rem; font: inherit; border: 1.5px solid var(--avad-neutral); border-radius: var(--radius-sm); background: var(--avad-white); color: var(--text); }
.role-form { display: flex; gap: .4rem; align-items: center; flex-wrap: wrap; }
.btn--icon { min-width: 44px; padding-left: .5rem; padding-right: .5rem; font-weight: 800; }
.preline { white-space: pre-line; overflow-wrap: anywhere; }
.worship-overview { margin-bottom: 1rem; }
.worship-event__sets { list-style: none; margin: .5rem 0 0; padding: 0; display: flex; flex-direction: column; gap: .4rem; }
.worship-event__sets li { display: flex; justify-content: space-between; align-items: center; gap: .5rem .75rem; flex-wrap: wrap; padding: .5rem .75rem; background: var(--avad-bg); border-radius: var(--radius-sm); font-size: .92rem; }
.worship-strip { border-left: 5px solid var(--avad-action); }
@media (max-width: 420px) {
    .setlist__item { grid-template-columns: 2.2rem 1fr; }
    .setlist__keys { grid-column: 2; flex-direction: row; gap: .5rem; justify-content: flex-start; }
}

@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* ---------- Telas de visitante: boas-vindas, entrar, criar conta e senha (25/10/2026) ---------- */
.page-auth, .page-landing {
    color: var(--avad-white);
    background-color: var(--avad-deep);
    background-image:
        radial-gradient(120% 60% at 50% -8%, rgba(13, 147, 157, .55) 0%, rgba(13, 147, 157, 0) 60%),
        radial-gradient(90% 45% at 50% 108%, rgba(212, 162, 90, .28) 0%, rgba(212, 162, 90, 0) 65%),
        repeating-conic-gradient(from 180deg at 50% -20%, rgba(255, 255, 255, .025) 0deg 3deg, rgba(255, 255, 255, 0) 3deg 11deg),
        linear-gradient(180deg, var(--avad-header) 0%, var(--avad-deep) 70%);
    background-attachment: fixed;
}
.page-auth .main, .page-landing .main { padding-top: 2rem; }
.page-auth .topbar, .page-landing .topbar { background: transparent; border-bottom-color: transparent; position: relative; }
.page-auth .footer, .page-landing .footer { color: #C9D6D9; border-top-color: rgba(255, 255, 255, .12); }
.page-auth .footer__muted, .page-landing .footer__muted { color: var(--avad-neutral); }

/* Botões em pílula */
.btn--pill { border-radius: 999px; min-height: 54px; font-size: 1.1875rem; letter-spacing: .01em; }
.btn--light { background: var(--avad-action); border-color: var(--avad-action); color: var(--avad-white); box-shadow: 0 8px 24px rgba(13, 147, 157, .35); }
.btn--light:hover { background: var(--avad-structure); border-color: var(--avad-action); color: var(--avad-white); }
.btn--outline-light { background: rgba(255, 255, 255, .04); border-color: rgba(255, 255, 255, .55); color: var(--avad-white); }
.btn--outline-light:hover { background: rgba(255, 255, 255, .12); border-color: var(--avad-white); color: var(--avad-white); }

/* Boas-vindas */
.welcome-hero { min-height: calc(100svh - 110px); display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 1rem 0 2.5rem; }
.welcome-hero__logo { width: min(400px, 92%); margin-bottom: 1.5rem; filter: drop-shadow(0 10px 30px rgba(0, 0, 0, .35)); }
.welcome-hero__lead { max-width: 480px; margin: 0 auto 2rem; color: #E6EEEF; font-size: 1.05rem; }
.welcome-hero__actions { display: flex; flex-direction: column; gap: .85rem; width: 100%; max-width: 360px; }
.welcome-hero__note { margin: 1.5rem 0 0; display: flex; flex-direction: column; align-items: center; gap: .6rem; }
.welcome-hero__sep { display: none; margin: 0 .6rem; color: var(--avad-neutral); }
@media (min-width: 560px) { .welcome-hero__note { flex-direction: row; gap: 0; } .welcome-hero__sep { display: inline; } }
.welcome-hero__note a, .auth-v2 a { color: var(--avad-white); text-decoration-color: var(--avad-accent); font-weight: 600; }
.welcome-hero__note a:hover, .auth-v2 a:hover { color: var(--avad-accent); }
.page-landing .feature { background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .1); border-bottom: 3px solid var(--avad-accent); backdrop-filter: blur(6px); }

/* Entrar, criar conta e senha */
.auth-v2 { display: flex; flex-direction: column; align-items: center; padding-top: .25rem; }
.auth-v2__home { display: block; border-radius: 12px; margin: 0 auto 1.25rem; }
.auth-v2__home:focus-visible { box-shadow: var(--focus); }
.auth-v2__logo { width: min(240px, 70vw); display: block; }
.auth-v2__card {
    width: 100%; max-width: 440px; padding: 1.75rem 1.25rem 1.5rem; border-radius: 22px;
    background: rgba(5, 24, 36, .55); border: 1px solid rgba(255, 255, 255, .12);
    box-shadow: 0 20px 50px rgba(0, 0, 0, .35); backdrop-filter: blur(10px);
}
.auth-v2__card h1 { color: var(--avad-white); text-align: center; font-size: 1.5rem; margin-bottom: .35rem; }
.auth-v2__intro { text-align: center; color: #C9D6D9; font-size: .95rem; margin-bottom: 1.5rem; }
.auth-v2 .field label { color: var(--avad-white); }
.auth-v2 .field input[type=text], .auth-v2 .field input[type=email], .auth-v2 .field input[type=password] { border-radius: 12px; border-color: transparent; min-height: 50px; }
.auth-v2 .field input:focus { border-color: var(--avad-action); box-shadow: 0 0 0 3px rgba(13, 147, 157, .45); }
.auth-v2 .password__toggle { border-radius: 12px; border-color: transparent; }
.auth-v2 .hint { color: #C9D6D9; }
.auth-v2 .field-error { color: var(--avad-white); }
.auth-v2 .alert a { color: var(--avad-structure); }
.auth-v2 .btn--pill { margin-top: .5rem; }
.auth-v2__links { text-align: center; margin: 1.1rem 0 0; }
.auth-v2__alt { text-align: center; margin: 1.25rem 0 0; color: #C9D6D9; }
@media (min-width: 640px) { .auth-v2__card { padding: 2rem 2rem 1.75rem; } }

/* ---------- Avisos flutuantes (toast) ---------- */
.toasts { position: fixed; z-index: 60; top: 12px; left: 12px; right: 12px; display: flex; flex-direction: column; align-items: center; gap: .5rem; pointer-events: none; }
@media (min-width: 640px) { .toasts { left: auto; right: 20px; top: 20px; align-items: flex-end; } }
.toast {
    pointer-events: auto; width: 100%; max-width: 380px; display: flex; align-items: flex-start; gap: .7rem;
    padding: .75rem .6rem .75rem .9rem; border-radius: 14px; border-left: 4px solid var(--avad-support);
    background: var(--avad-header); color: var(--avad-white); box-shadow: 0 12px 32px rgba(5, 24, 36, .35);
    animation: toast-in .25s ease-out; transition: opacity .25s ease, transform .25s ease;
}
.toast.is-leaving { opacity: 0; transform: translateY(-8px); }
.toast--success { border-left-color: var(--avad-action); }
.toast--error { border-left-color: var(--avad-accent); }
.toast__icon { flex: 0 0 24px; width: 24px; height: 24px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: .85rem; font-weight: 800; margin-top: .05rem; background: var(--avad-support); color: var(--avad-white); }
.toast--success .toast__icon { background: var(--avad-action); }
.toast--error .toast__icon { background: var(--avad-accent); color: var(--avad-deep); }
.toast__text { flex: 1; margin: .1rem 0 0; font-size: .95rem; line-height: 1.4; color: var(--avad-white); }
.toast__text strong { font-weight: 700; }
.toast__close { flex: 0 0 auto; width: 36px; height: 36px; margin: -.3rem 0 -.3rem 0; border: 0; border-radius: 10px; background: none; color: #C9D6D9; font-size: 1.4rem; line-height: 1; cursor: pointer; }
.toast__close:hover { background: rgba(255, 255, 255, .1); color: var(--avad-white); }
@keyframes toast-in { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .toast { animation: none; transition: none; } }
/* Sem JavaScript o aviso não pode ser fechado: fica no fluxo da página, no topo do conteúdo. */
.no-js .toasts { position: static; margin-bottom: 1rem; align-items: stretch; }
.no-js .toast { max-width: none; }
.no-js .toast__close { display: none; }
/* Telas de fundo escuro: borda clara fina para o aviso se destacar do fundo. */
.page-auth .toast, .page-landing .toast { border-top: 1px solid rgba(255, 255, 255, .16); border-right: 1px solid rgba(255, 255, 255, .16); border-bottom: 1px solid rgba(255, 255, 255, .16); }
/* Borda clara para o aviso não se confundir com o fundo escuro das telas de visitante. */
.toast { border-top: 1px solid rgba(255, 255, 255, .14); border-right: 1px solid rgba(255, 255, 255, .14); border-bottom: 1px solid rgba(255, 255, 255, .14); }

/* ---------- Brain AVAD: Indicadores ---------- */
.stats { margin: 0 0 1.5rem; }
.stats__title { font-size: 1.05rem; color: var(--avad-structure); margin: 0 0 .6rem; }
.stats__grid { display: grid; gap: .6rem; grid-template-columns: repeat(2, minmax(0, 1fr)); margin: 0; }
@media (min-width: 640px) { .stats__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 980px) { .stats__grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.stat { background: var(--avad-white); border: 1px solid rgba(155, 165, 168, .25); border-left: 4px solid var(--avad-support); border-radius: var(--radius-sm); padding: .7rem .85rem; box-shadow: var(--shadow); min-width: 0; }
.stat dt { font-size: .85rem; color: var(--text-muted); line-height: 1.3; }
.stat dd { margin: .2rem 0 0; font-size: 1.6rem; font-weight: 700; color: var(--avad-deep); line-height: 1.2; font-variant-numeric: tabular-nums; }
.stat--ok { border-left-color: var(--avad-action); }
.stat--warn { border-left-color: var(--avad-neutral); }
.stat--accent { border-left-color: var(--avad-accent); background: #FBF3E6; }
.stats__table-title { font-size: 1.05rem; color: var(--avad-structure); margin: 0; padding: 1rem 1.25rem .75rem; }
.table .num { text-align: right; font-variant-numeric: tabular-nums; }
