@import url('./tokens.css');
@import url('./date-picker.css?v=20261020');
@import url('./community-summary.css?v=20261015-columns');
@import url('./estate.css');
@import url('./community-people.css');
@import url('./community-organization.css');
@import url('./community-elements.css');
@import url('./community-meetings.css');
@import url('./community-tasks.css');
@import url('./community-links.css');
@import url('./community-empty.css');
@import url('./community-forms.css?v=20261020-spacing');
@import url('./invitation.css?v=20261023-delegate');
/* Tabler supplies components; this layer preserves accessible sizing and domain layouts. */
.economy-budget-panel { border: 1px solid var(--line); border-radius: 14px; background: white; margin: 0 0 24px; }
.economy-budget-panel > summary { list-style: none; display: flex; align-items: center; gap: 14px; cursor: pointer; padding: 20px; }
.economy-budget-panel > summary::-webkit-details-marker { display: none; }
.economy-budget-panel > summary > svg { width: 24px; height: 24px; flex-shrink: 0; color: var(--brand); }
.economy-budget-panel > summary > span { flex: 1; min-width: 0; }
.economy-budget-panel summary strong { display: block; font-size: .95rem; font-weight: 500; }
.economy-budget-panel summary small { display: block; font-size: .8rem; color: var(--muted); margin-top: 4px; }
.economy-budget-panel[open] > summary .economy-accordion-arrow { transform: rotate(180deg); }
.economy-budget-content { padding: 20px; border-top: 1px solid var(--line); }
.agenda-expense-accordion { margin-top: 24px; border: 1px solid var(--line); border-radius: 12px; }
.agenda-expense-accordion > summary { display: flex; gap: 12px; align-items: center; padding: 16px; cursor: pointer; list-style: none; }
.agenda-expense-accordion > summary::-webkit-details-marker { display: none; }
.agenda-expense-accordion summary > svg { width: 24px; height: 24px; flex-shrink: 0; color: var(--brand); }
.agenda-expense-accordion summary > span { flex: 1; }
.agenda-expense-accordion summary strong { display: block; font-size: .9rem; font-weight: 500; }
.agenda-expense-accordion summary small { display: block; font-size: .8rem; color: var(--muted); margin-top: 4px; }
.agenda-expense-accordion[open] .agenda-expense-arrow { transform: rotate(180deg); }
.agenda-expense-accordion > form { border-top: 1px solid var(--line); padding: 16px; }
.agenda-expense-accordion .form-label { font-size: .85rem; font-weight: 500; }
.agenda-expense-accordion form .actions { margin-top: 16px; }
/* Orden del día: conservar la lista numerada y alinear cada acción al borde interior. */
[aria-labelledby="agenda-title"] > ol { margin: 0; padding-left: 26px; }
[aria-labelledby="agenda-title"] > ol > li { position: relative; padding: 18px 0; min-height: 78px; }
[aria-labelledby="agenda-title"] > ol > li + li { border-top: 1px solid #dfe3e8; }
[aria-labelledby="agenda-title"] > ol > li:has(> form) { padding-right: 152px; }
[aria-labelledby="agenda-title"] > ol > li > strong { display: block; }
[aria-labelledby="agenda-title"] > ol > li > p { margin: 4px 0 0; }
[aria-labelledby="agenda-title"] > ol > li > p:empty { display: none; }
[aria-labelledby="agenda-title"] > ol > li > form { position: absolute; right: 0; top: 50%; transform: translateY(-50%); margin: 0; }
@media (max-width: 640px) {
    [aria-labelledby="agenda-title"] > ol > li:has(> form) { padding-right: 0; }
    [aria-labelledby="agenda-title"] > ol > li > form { position: static; transform: none; display: flex; justify-content: flex-end; margin-top: 12px; }
}
.attendance-sign-dialog, .delegate-dialog { max-height: calc(100dvh - 32px); overflow-y: auto; }
dialog.attendance-sign-dialog { width: min(680px, calc(100% - 32px)); }
.attendance-sign-dialog .check { font-size: .85rem; }
.attendance-sign-dialog h2, .delegate-dialog h2 { font-size: 1.15rem; }
.attendance-sign-dialog p, .delegate-dialog p { font-size: .85rem; }
.attendance-sign-dialog .actions, .delegate-dialog .actions { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); }
[data-signature-canvas] { display: block; width: 100%; height: 180px; border: 1px solid #a4b1c4; border-radius: 12px; background: white; touch-action: none; margin-bottom: 14px; }
.attendance-saved-signature { max-width: 210px; color: var(--ink); }
.attendance-saved-signature svg { display: block; width: 100%; height: 70px; }
.attendance-saved-signature small { display: block; color: var(--muted); font-size: .72rem; }
.attendance-export { margin: 16px 0 24px; flex-wrap: wrap; }
.delegate-dialog .form-label { font-size: .85rem; font-weight: 500; }
.delegate-dialog .form-control { font-size: .85rem; min-height: 40px; }
.economy-form-accordion { border: 1px solid var(--line); border-radius: 14px; background: white; margin: 0 0 16px; box-shadow: 0 2px 5px rgb(20 50 70 / 4%); min-width: 0; }
.economy-form-accordion > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 14px; padding: 20px; border-radius: 14px; }
.economy-form-accordion > summary::-webkit-details-marker { display: none; }
.economy-form-accordion > summary:hover { background: #f7fafc; }
.economy-form-accordion > summary > .economy-accordion-icon { display: grid; place-items: center; flex: 0 0 42px; width: 42px; height: 42px; border-radius: 12px; background: #eef6fc; color: var(--brand); }
.economy-accordion-icon svg { width: 24px; height: 24px; }
.economy-accordion-label { flex: 1; min-width: 0; }
.economy-accordion-label strong { display: block; font-size: .95rem; font-weight: 500; color: var(--ink); }
.economy-accordion-label > span { display: block; font-size: .8rem; font-weight: 400; color: var(--muted); margin-top: 4px; }
.economy-form-accordion > summary > .economy-accordion-arrow { display: grid; place-items: center; flex: 0 0 24px; color: var(--brand); width: 24px; height: 24px; transition: transform .15s; }
.economy-accordion-arrow > svg { display: block; width: 24px; height: 24px; }
.economy-form-accordion[open] > summary .economy-accordion-arrow { transform: rotate(180deg); }
.economy-form-accordion > .form-panel { border: 0; border-top: 1px solid var(--line); border-radius: 0 0 14px 14px; box-shadow: none; max-width: none; margin: 0; padding: 20px; }
.convocation-form-accordion > .form-panel { border-left: 0; }
.convocation-form-accordion form > .btn:last-child { margin-top: 18px; }
.attendance-debt-accordion > .panel { margin: 0; border: 0; border-top: 1px solid var(--line); border-radius: 0 0 14px 14px; box-shadow: none; }
.attendance-debt-accordion form > .btn:last-child { margin: 18px 0; }
.attendance-debt-accordion .table-responsive { overflow-x: auto; }
.attendance-debt-accordion > summary .economy-accordion-label strong { font-size: 16px; }
.attendance-debt-accordion > summary .economy-accordion-label > span { font-size: 13px; line-height: 1.5; }
.attendance-debt-accordion > .panel { font-size: 14px; line-height: 1.6; }
.attendance-debt-accordion h4 { font-size: 16px; font-weight: 600; margin: 22px 0 10px; }
.attendance-debt-accordion .table { font-size: 14px; }
.attendance-debt-accordion .table thead th { font-size: 13px; }
.attendance-debt-accordion .form-label { font-size: 13px; font-weight: 500; margin-bottom: 4px; }
.attendance-debt-accordion .form-control, .attendance-debt-accordion .form-select { font-size: 14px; min-height: 38px; padding: 6px 10px; }
.attendance-debt-accordion .form-select { padding-right: 38px; }
.attendance-debt-accordion textarea.form-control { min-height: 76px; }
.attendance-debt-accordion .btn { font-size: 14px; min-height: 38px; padding: 6px 16px; }
body[data-view="/Comunidades/Economia"] .economy-form-grid { display: block; }
body[data-view="/Comunidades/Economia"] .economy-form-accordion > .form-panel { border-left: 0; }
.economy-form-accordion .actions { margin-top: 20px; }
@media (max-width: 640px) { .economy-form-accordion > summary { padding: 16px; gap: 10px; } .economy-accordion-label > span { font-size: .78rem; } }
html { font-size:18px; }body { margin:0; font-family:var(--tblr-font-sans-serif); font-size:1rem; line-height:1.6; color:var(--ink); background:var(--canvas); }
a { color:var(--brand); text-underline-offset:4px; }a:hover { color:var(--brand-dark); }
h1,h2,h3 { line-height:1.25; letter-spacing:-.025em; color:var(--ink); }h1 { font-size:2rem; margin:0 0 12px; }h2 { font-size:1.35rem; margin:0 0 18px; }h3 { font-size:1.1rem; }p { margin:0 0 1rem; }
:focus-visible { outline:3px solid var(--focus)!important; outline-offset:4px; }.skip-link { position:absolute; top:-100px; left:16px; padding:12px; background:white; z-index:1100; }.skip-link:focus { top:8px; }
.topbar { position:sticky; top:0; z-index:100; padding:7px 28px; min-height:70px; display:flex; align-items:center; justify-content:space-between; gap:20px; background:white; border-bottom:1px solid var(--line); }.brand-group,.top-actions { display:flex; align-items:center; gap:22px; }.brand { display:flex; align-items:center; gap:12px; text-decoration:none; color:var(--ink); font-size:1.15rem; font-weight:750; }.brand small { display:block; font-size:.7rem; font-weight:500; color:var(--muted); }.brand-mark { display:grid; place-items:center; width:44px; height:44px; border-radius: var(--radius-sm); background:var(--brand); color:white; font-size:1.4rem; }.top-actions form { margin:0; }.demo-label { font-size:.75rem; }.location-bar { display:flex; flex-wrap:wrap; align-items:center; gap:10px; padding:14px 32px; border-bottom:1px solid var(--line); background:#fff; font-size:.9rem; }.location-bar a { padding:5px 0; }.current-community { font-weight:700; }.change-community { margin-left:auto; }
.app-shell { min-height:75vh; }.content { padding:34px 32px; max-width:1440px; min-width:0; margin:auto; }.page-heading { display:flex; align-items:flex-start; justify-content:space-between; gap:24px; margin-bottom:28px; }.page-heading p { color:var(--muted); }.eyebrow { font-size:.75rem; letter-spacing:.1em; font-weight:700; color:var(--muted); margin-bottom:10px; }.page-footer { border-top:1px solid var(--line); margin-top:40px; padding-top:22px; color:var(--muted); font-size:.82rem; }
.btn { min-height:42px; padding:7px 13px; font-size:14px; font-weight:600; border-radius: var(--radius-sm); white-space:normal; gap:8px; }.btn-primary { --tblr-btn-bg:var(--brand); --tblr-btn-border-color:var(--brand); --tblr-btn-hover-bg:var(--brand-dark); --tblr-btn-hover-border-color:var(--brand-dark); background:var(--brand); border-color:var(--brand); color:white; }.btn-outline-secondary { color:var(--brand-dark); border-color:#a7b4c7; background:white; }.btn-outline-secondary:hover { background:var(--soft); color:var(--brand-dark); border-color:var(--brand); }.btn:disabled { cursor:not-allowed; opacity:.6; }.btn.community-action-compact { min-height:34px; padding:4px 9px; font-size:14px; }.button { text-decoration:none; }.actions { display:flex; flex-wrap:wrap; align-items:center; gap:12px; margin-top:22px; }.back-link { display:inline-block; padding:10px 0; margin-bottom:18px; }
.card { border-color:var(--line); border-radius:var(--radius-lg); box-shadow:var(--shadow); }.card-body,.panel,.card-panel { padding:26px; }.panel,.card-panel { margin-bottom:24px; }.card-header { padding:22px 26px; gap:18px; justify-content:space-between; }.card-title { font-size:1.2rem; margin:0; }.cards { display:grid; grid-template-columns:repeat(auto-fit,minmax(min(290px,100%),1fr)); gap:22px; }.cards .card-panel { margin-bottom:0; }.community-card { display:flex; flex-direction:column; border-top:3px solid #7d9ecf; }.community-card h2 a { text-decoration:none; }.community-card-actions { margin-top:auto; }.badge-state { display:inline-block; padding:4px 10px; color:#244876; background:#edf2fa; border:1px solid #cdd9eb; border-radius: var(--radius-sm); font-size:.82rem; font-weight:600; }.split { display:grid; grid-template-columns:1fr 1fr; gap:24px; }.stat { font-size:2rem; font-weight:700; }.stat-label,.muted,.help,.hint { color:var(--muted); }.help,.hint { font-size:.9rem; margin:8px 0 18px; }
.form-label { font-size:1rem; font-weight:600; margin-bottom:8px; display:block; }.form-control,.form-select { font-size:1rem; min-height:48px; padding:11px 13px; border-color:#a4b1c4; border-radius: var(--radius-sm); color:var(--ink); }.form-select { padding-right:38px; }textarea.form-control { min-height:120px; }input[readonly] { background:var(--canvas); }.form-check-input { width:24px; height:24px; flex-shrink:0; margin-right:8px; float:none; vertical-align:middle; }.check,.check-label { display:flex; align-items:center; gap:10px; margin:16px 0; font-weight:400; }.form-panel { max-width:850px; }.field { margin-bottom:22px; }.form-grid { display:grid; grid-template-columns:1fr 1fr; gap:0 24px; }form>input:not([type=hidden]),form>select,form>textarea { margin-bottom:20px; }.search-bar { display:flex; gap:16px; align-items:flex-end; flex-wrap:wrap; margin-bottom:26px; }.search-bar>div { flex:1; min-width:180px; }.search-bar a { padding:10px; }
.notice,.callout { padding:18px 22px; background:var(--soft); border-left:4px solid var(--brand); border-radius: var(--radius-sm); margin-bottom:24px; }.notice.error { background:#fff0f1; color:#8d1d2a; border-color:#b33745; }.notice.warning { background:#fff6df; color:#70520b; border-color:#a87808; }.field-validation-error { color:var(--danger); display:block; }.validation-summary-valid { display:none; }
.tabs { display:flex; flex-wrap:wrap; gap:6px; padding:0 0 16px; margin:0 0 26px; border-bottom:1px solid var(--line); }.tabs a { padding:11px 16px; border-radius: var(--radius-sm); text-decoration:none; }.tabs a[aria-current] { background:var(--brand); color:#fff; }.table-wrap { overflow-x:auto; border:1px solid var(--line); border-radius: var(--radius-md); margin:18px 0; }.table { margin:0; font-size:1rem; background:white; }.table th,.table td { padding:16px 18px; }.table thead th { background:#f0f3f8; color:#40536e; font-size:.82rem; letter-spacing:.025em; font-weight:700; }.table caption { caption-side:top; padding:16px 18px; color:var(--ink); font-weight:600; }td form { display:inline-block; }.table-wrap input { min-width:100px; }.list-row { display:flex; align-items:center; justify-content:space-between; gap:18px; padding:18px 0; border-bottom:1px solid var(--line); }.empty-state { text-align:center; border:1px dashed #a3b1c7; border-radius: var(--radius-md); padding:30px; margin:20px 0; background:#f9fbfe; }.timeline { padding-left:24px; }.timeline li { padding:10px 0; border-bottom:1px solid var(--line); }dl { display:grid; grid-template-columns:minmax(130px,1fr) 2fr; gap:12px; }dt,dd { margin:0; }summary { min-height:48px; padding:10px 0; cursor:pointer; font-weight:600; }details { margin-bottom:14px; }.preserve-lines,.prose { white-space:pre-wrap; }.operation-area { min-width:0; }.account-wrap,.auth-panel { max-width:620px; margin:24px auto; }.account-wrap.wide { max-width:820px; }.panel,.content { overflow-wrap:anywhere; }
body.navigation-open { overflow:hidden; }.site-menu { position:fixed; inset:0 auto 0 0; margin:0; width:min(390px,100%); max-width:100%; height:100dvh; max-height:100dvh; padding:0; border:0; background:#fff; color:var(--ink); overflow-y:auto; overscroll-behavior:contain; box-shadow:10px 0 40px #14294726; }.site-menu::backdrop { background:rgb(20 35 56 / 45%); }.menu-header { display:flex; gap:16px; justify-content:space-between; align-items:center; position:sticky; top:0; z-index:1; padding:20px; background:#fff; border-bottom:1px solid var(--line); }.menu-header h2 { font-size:1.1rem; margin:0; }.menu-header .btn { flex-shrink:0; }.menu-content { padding:24px; }.menu-content .nav-link,.side-nav a { padding:12px 14px; min-height:48px; color:var(--ink); text-decoration:none; border-radius: var(--radius-sm); }.menu-content [aria-current],.side-nav a[aria-current] { background:var(--soft); color:var(--brand-dark); font-weight:700; border-left:3px solid var(--brand); }.side-nav { display:grid; gap:4px; margin-top:20px; }.community-name { font-size:1.2rem; }.sidebar-help { margin-top:24px; padding-top:18px; border-top:1px solid var(--line); color:var(--muted); font-size:.85rem; }.menu-hint { margin-top:26px; }
.dashboard-metrics { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:20px; margin-bottom:28px; }.metric-card { padding:24px; display:flex; flex-direction:row; align-items:flex-start; gap:16px; text-decoration:none; }.metric-card:hover { border-color:#92abd1; }.metric-icon { display:grid; place-items:center; background:var(--soft); color:var(--brand); border-radius: var(--radius-md); width:48px; height:48px; flex-shrink:0; font-size:1.5rem; }.metric-label { display:block; font-size:.85rem; font-weight:600; color:var(--muted); }.metric-card strong { display:block; font-size:2.25rem; line-height:1.5; color:var(--ink); }.metric-card small { display:block; font-size:.75rem; color:var(--muted); }.dashboard-columns { display:grid; grid-template-columns:1.25fr 1fr; gap:24px; margin-bottom:26px; }.dashboard-community { display:flex; gap:16px; align-items:center; padding:20px 26px; }.dashboard-community small { display:block; font-size:.85rem; color:var(--muted); }.row-arrow { margin-left:auto; color:var(--brand); }.dashboard-event+ .dashboard-event { margin-top:24px; padding-top:24px; border-top:1px solid var(--line); }.dashboard-table { border:0; margin:0; border-radius:0 0 var(--radius-md) var(--radius-md); }
@media(max-width:1100px) { .dashboard-metrics { grid-template-columns:repeat(2,1fr); }.page-heading { flex-wrap:wrap; }.demo-label { display:none; } }
@media(max-width:720px) { .topbar { position:sticky; top:0; z-index:100; padding:7px 16px; gap:6px; flex-wrap:wrap; }.brand-group { gap:12px; }.top-actions { width:100%; justify-content:flex-end; gap:18px; }.location-bar { padding:12px 16px; }.change-community { margin-left:0; }.content { padding:24px 16px; }.split,.dashboard-columns { grid-template-columns:1fr; }.dashboard-metrics { gap:12px; }.metric-card { padding:16px; flex-direction:column; gap:8px; }.metric-icon { width:38px; height:38px; }.card-body,.panel,.card-panel,.card-header { padding:20px; }.form-grid { grid-template-columns:1fr; }.list-row { flex-wrap:wrap; }h1 { font-size:1.65rem; }dl { grid-template-columns:1fr; gap:4px; }dd { margin-bottom:12px; }.card-header { flex-wrap:wrap; } }
@media(prefers-reduced-motion:reduce) { * { scroll-behavior:auto!important; transition:none!important; animation:none!important; } }
@media print { .topbar,.location-bar,dialog,nav,form,.actions,.page-footer { display:none!important; }.content { padding:0; }.card { box-shadow:none; break-inside:avoid; } }

[id] { scroll-margin-top:115px; }
@media(max-width:720px) { [id] { scroll-margin-top:175px; } }
/* Asistencia: lista dinámica y animaciones */
.attendance-list { display:flex; flex-direction:column; gap:12px; margin-bottom:18px; }
.attendance-item { padding:12px 16px; margin-bottom:0; border-radius:var(--radius-md); border:1px solid var(--line); background:var(--paper); box-shadow:var(--shadow); animation: attendanceSlideIn .26s ease both; }
.attendance-item-main { display:flex; align-items:center; justify-content:space-between; gap:16px; width:100%; }
.attendance-item-content { flex:1; min-width:0; text-align:left; }
.attendance-item h3 { margin:0 0 2px; font-size:1.02rem; }
.attendance-item p { margin:0 0 2px; color:var(--muted); line-height:1.3; }
.attendance-item p:last-child { margin-bottom:0; }
.attendance-participation { font-size:.95rem; }
.attendance-item-controls { flex-shrink:0; display:flex; flex-wrap:wrap; align-items:center; justify-content:flex-end; gap:12px; padding-left:12px; }
.attendance-item-controls form { margin:0; }
.attendance-item-controls .btn { min-width:144px; min-height:42px; padding:8px 14px; font-size:.8rem; line-height:1.4; font-weight:500; margin:0; }
@keyframes attendanceSlideIn { from { opacity:0; transform: translateY(-8px); } to { opacity:1; transform:none; } }
.attendance-list .attendance-item.new { box-shadow: 0 10px 30px rgba(2,10,12,0.07); border-color: rgba(3,45,58,0.06); }
.attendance-item.attendance-duplicate { border-color:#b33745; box-shadow:0 0 0 3px #f5c6cb; transition: box-shadow .3s ease, border-color .3s ease; }
#attendance-form-error { margin-bottom:16px; }
.attendance-form-submitting { opacity:0.6; pointer-events:none; }
@media (max-width:600px) { .attendance-item-main { flex-direction:column; align-items:flex-start; gap:10px; } .attendance-item-controls { padding-left:0; justify-content:flex-start; max-width:100%; } }

.ballot { margin:0 0 28px; }
.ballot-head { display:flex; align-items:flex-start; justify-content:space-between; gap:16px; margin:0 0 14px; }
.ballot-head h3 { margin:0; color:var(--brand-dark); font-size:1.25rem; }
.ballot-head .eyebrow { margin-bottom:4px; }
.ballot-state.is-open { color:#1f6f64; background:#e7f6f2; border-color:#b7e0d6; }
.ballot-state.is-closed { color:#5b6474; background:#eef1f5; border-color:#d5dbe4; }
.ballot-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:14px; align-items:stretch; }
.ballot-card { min-width:0; margin:0; padding:18px 20px; background:#fff; }
.ballot-card h2 { margin:0 0 8px; color:var(--brand-dark); font-size:1.05rem; }
.ballot-results { margin:8px 0 0; }
.ballot-results .table { width:100%; }
.ballot-results .table th, .ballot-results .table td { padding:14px 16px; vertical-align:middle; }
.ballot-leading { background:#f4fbfa; }
.ballot-leading > th { color:var(--brand-dark); }
.ballot-leading-badge { margin-left:8px; font-size:.72rem; font-weight:700; }
.ballot-coef { display:flex; align-items:center; gap:10px; font-weight:650; white-space:nowrap; }
.ballot-coef-bar { display:inline-block; width:88px; height:8px; background:#e7eef3; border-radius:999px; overflow:hidden; }
.ballot-coef-bar > span { display:block; height:100%; background:var(--brand); border-radius:inherit; }
.ballot-vote-form .field { margin-bottom:16px; }
.ballot-vote-form .actions { margin-top:8px; }
.ballot-close-form { display:flex; align-items:center; gap:12px; margin-top:18px; padding-top:16px; border-top:1px solid var(--line); }
.ballot-history { margin:16px 0 0; }
.ballot-history-list { margin:0; padding:0; list-style:none; }
.ballot-history-list li { padding:8px 0; border-bottom:1px solid var(--line); font-size:.95rem; }
.ballot-history-list li.is-superseded { color:var(--muted); }
.ballot-new { max-width:none; }
@media (max-width:991.98px) { .ballot-grid { grid-template-columns:1fr; } .ballot-head { flex-wrap:wrap; } }

/* Corporate artwork supplied by the user. Kept as original sheets, framed by SVG. */
.brand-symbol { width:42px; height:47px; flex-shrink:0; }
.brand-name { display:block; color:#09254d; font-size:.88rem; line-height:1.2; }
.brand small { margin-top:3px; padding-left:8px; border-left:3px solid var(--accent); }
.brand-icon { display:inline-block; width:38px; height:32px; flex-shrink:0; overflow:hidden; vertical-align:middle; mix-blend-mode:multiply; }
.menu-content .nav-link,.side-nav a,.top-actions>a { display:flex; align-items:center; gap:12px; }
.metric-card>.brand-icon { width:85px; height:70px; }
.community-card { border-top-color:var(--accent); }
.menu-content [aria-current],.side-nav a[aria-current] { border-left-color:var(--accent-dark); }
.bg-blue-lt { background:var(--soft)!important; color:var(--brand-dark)!important; }
.badge-state { color:var(--brand-dark); background:var(--soft); border-color:var(--line); }
.topbar { border-bottom:1px solid var(--accent); }
@media (min-width:721px) {
    .community-workspace .topbar { position:fixed; top:0; left:0; right:0; z-index:120; box-sizing:border-box; min-height:70px; }
    .community-workspace .location-bar { margin-top:70px; }
}

/* Economía: el periodo contextualiza todas las tablas del apartado. */
body[data-view="/Comunidades/Economia"] #main > form:has(> #periodId) {
    display: grid;
    grid-template-columns: auto minmax(180px, 1fr) auto;
    align-items: center;
    gap: 12px 18px;
    padding: 16px 20px;
    border: 1px solid #cbdfea;
    border-left: 4px solid var(--brand);
    background: #eef6fc;
}
body[data-view="/Comunidades/Economia"] #main > form:has(> #periodId) > * { margin: 0; }
body[data-view="/Comunidades/Economia"] #main > form:has(> #periodId) .form-label {
    color: var(--ink);
    font-size: 1rem;
    font-weight: 600;
}
body[data-view="/Comunidades/Economia"] #main > form:has(> #periodId) .btn { min-height: 44px; }
body[data-view="/Comunidades/Economia"] .table-responsive:has(> .table) {
    margin: 18px 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    overflow-x: auto;
}
body[data-view="/Comunidades/Economia"] .table {
    width: 100%;
    margin: 0;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    border-collapse: separate;
    border-spacing: 0;
    font-family: inherit;
    font-size: 1rem;
    line-height: 1.5;
}
body[data-view="/Comunidades/Economia"] .table caption {
    padding: 0 0 12px;
    background: transparent;
    border: 0;
    font-size: 1rem;
    font-weight: 600;
}
body[data-view="/Comunidades/Economia"] .table thead th {
    padding: 12px 18px;
    background: var(--canvas);
    color: var(--muted);
    font-family: inherit;
    font-size: .9rem;
    font-weight: 600;
    text-transform: none;
    letter-spacing: normal;
}
body[data-view="/Comunidades/Economia"] .table tbody th,
body[data-view="/Comunidades/Economia"] .table tbody td {
    padding: 12px 18px;
    border-color: var(--line);
    font-size: .9rem;
    font-weight: 400;
    vertical-align: middle;
}
body[data-view="/Comunidades/Economia"] .table tbody th { font-weight: 500; }
body[data-view="/Comunidades/Economia"] .table tbody tr:last-child > * { border-bottom: 0; }
body[data-view="/Comunidades/Economia"] .table td { font-variant-numeric: tabular-nums; }
body[data-view="/Comunidades/Economia"] .table tbody tr:hover > * { background: #f4f9fd; }
/* Primera columna identificativa azul, datos blancos y títulos fuera del borde. */
body[data-view="/Comunidades/Economia"] .table thead th {
    background: var(--brand);
    color: #fff;
    border-bottom-color: var(--brand);
}
body[data-view="/Comunidades/Economia"] .table thead th:first-child { border-top-left-radius: 11px; }
body[data-view="/Comunidades/Economia"] .table thead th:last-child { border-top-right-radius: 11px; }
body[data-view="/Comunidades/Economia"] .table tbody tr > :first-child {
    background: #eef6fc;
    color: var(--ink);
    font-weight: 500;
    border-right: 1px solid var(--line);
}
body[data-view="/Comunidades/Economia"] .table tbody tr > :not(:first-child) { background: var(--paper); }
body[data-view="/Comunidades/Economia"] .table tbody tr:last-child > :first-child { border-bottom-left-radius: 11px; }
body[data-view="/Comunidades/Economia"] .table tbody tr:last-child > :last-child { border-bottom-right-radius: 11px; }
body[data-view="/Comunidades/Economia"] .table tbody th[scope="row"] + td { white-space: nowrap; }
body[data-view="/Comunidades/Economia"] .table tbody th[scope="row"] {
    font-size: .9rem;
    font-weight: 500;
}
@media (max-width: 900px) {
    body[data-view="/Comunidades/Economia"] #main > form:has(> #periodId) { grid-template-columns: minmax(0, 1fr) auto; }
    body[data-view="/Comunidades/Economia"] #main > form:has(> #periodId) .form-label { grid-column: 1 / -1; }
}
@media (max-width: 540px) {
    body[data-view="/Comunidades/Economia"] #main > form:has(> #periodId) { grid-template-columns: minmax(0, 1fr); padding: 14px 16px; }
}
.topbar .btn { min-height:44px; padding:7px 12px; font-size:.88rem; font-weight:500; box-shadow:none; }
.topbar .menu-toggle { border-color:transparent; background:transparent; gap:7px; }
.topbar .menu-toggle:hover { border-color:var(--line); background:var(--soft); }
.menu-toggle svg { width:18px; height:18px; stroke-width:1.6; }
.top-actions { gap:16px; font-size:.88rem; }
.top-actions .brand-icon { width:28px; height:24px; }
@media(max-width:1100px) { .brand-group { gap:14px; }.brand-name { font-size:.9rem; } }
@media(max-width:720px) { .brand-group { width:100%; gap:10px; }.brand { gap:8px; flex:1; min-width:0; }.brand-symbol { width:38px; height:43px; }.brand-name { font-size:.74rem; }.brand small { font-size:.65rem; }.metric-card>.brand-icon { width:54px; height:44px; } }
.footer-ownership { display:flex; flex-wrap:wrap; align-items:center; gap:10px 16px; font-size:.78rem; color:var(--muted); }
.flashdata-brand { display:inline-flex; align-items:center; padding:6px 10px; border-radius: var(--radius-sm); background:#111b32; flex-shrink:0; }
.flashdata-logo { display:block; width:105px; max-width:100%; height:auto; }
.footer-demo { margin:8px 0 0; font-size:.75rem; color:var(--muted); }
@media(max-width:720px) { .footer-ownership { flex-direction:column; align-items:flex-start; gap:12px; } }
/* Community navigation stays docked on tablets and larger screens. */
.community-sidebar { display:none; }
@media (min-width:768px) {
    .community-workspace .app-shell { display:grid; grid-template-columns:250px minmax(0,1fr); align-items:start; }
    .community-sidebar { display:block; position:sticky; top:76px; height:calc(100dvh - 76px); max-height:none; box-sizing:border-box; overflow-y:auto; overscroll-behavior:contain; padding:24px 16px; background:var(--paper); border-right:1px solid var(--line); }
    .community-sidebar .eyebrow { font-size:.7rem; }
    .community-sidebar .community-name { margin-bottom:8px; }
    .community-sidebar .side-nav { margin-top:16px; }
    .community-sidebar .side-nav a { padding:9px 8px; gap:8px; font-size:.86rem; }
    .community-sidebar .brand-icon { width:32px; height:28px; }
    .community-sidebar .sidebar-help { display:none; }
    .sidebar-all-communities { display:block; margin-top:18px; padding:12px 10px; border-top:1px solid var(--line); }
    .community-workspace.sidebar-collapsed .app-shell { grid-template-columns:minmax(0,1fr); }
    .community-workspace.sidebar-collapsed .community-sidebar { display:none; }
}
@media (min-width:1200px) {
    .community-workspace .app-shell { grid-template-columns:280px minmax(0,1fr); }
    .community-sidebar .side-nav a { padding:10px; gap:10px; font-size:.9rem; }
    .community-sidebar .brand-icon { width:40px; height:30px; }
    .community-workspace .content { width:100%; padding:28px 24px; }
}
@media print {
    .community-sidebar { display:none!important; }
    .community-workspace .app-shell { display:block; }
}
.action-confirmation { width:min(560px,calc(100% - 32px)); border:1px solid var(--line); border-radius: var(--radius-md); padding:28px; color:var(--ink); background:var(--paper); box-shadow:var(--shadow); }
.action-confirmation::backdrop { background:rgb(20 35 56 / 45%); }
#supplier-dialog { width: min(560px, calc(100% - 32px)); max-height: calc(100dvh - 32px); overflow-y: auto; padding: 24px; }
#supplier-dialog h2 { font-size: 1.15rem; margin-bottom: 10px; }
#supplier-dialog > p { font-size: .85rem; color: var(--muted); line-height: 1.5; margin-bottom: 18px; }
#supplier-dialog [data-supplier-error]:empty { display: none; }
#supplier-dialog [data-supplier-error]:not(:empty) { color: var(--ink); border-left: 3px solid var(--brand); background: var(--canvas); border-radius: 8px; padding: 10px 12px; }
#supplier-dialog .form-label { font-size: .8rem; font-weight: 500; margin-bottom: 6px; }
#supplier-dialog .form-control, #supplier-dialog .form-select { font-size: .85rem; min-height: 40px; padding: 8px 12px; margin-bottom: 14px; }
#supplier-dialog .actions { margin-top: 6px; padding-top: 16px; border-top: 1px solid var(--line); gap: 10px; }
@media (max-width: 640px) {
    #supplier-dialog { padding: 18px; }
    #supplier-dialog .actions { flex-wrap: wrap; }
}
[data-group-fields] { margin:24px 0; padding:18px; border:1px solid var(--line); border-radius: var(--radius-sm); }
[data-group-fields][hidden] { display:none; }

/* Domicilio compartido: etiquetas visibles y una sola columna con zoom o en móvil. */
.address-fields { margin: 28px 0; border: 1px solid var(--line); border-radius: var(--radius-md); padding: 20px; min-width: 0; }
.address-fields legend { float: none; width: auto; padding: 0 8px; font-size: 1.15rem; font-weight: 650; }
.address-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 20px; }
.address-grid .field { min-width: 0; }
@media (max-width: 700px) { .address-grid { grid-template-columns: 1fr; } .address-fields { padding: 14px; } }

/* =========================================================
   LOGIN
   ========================================================= */


/* =========================================================
   1. VARIABLES DEL LOGIN
   ========================================================= */

body:has(.account-wrap) {
    --login-navy: #08295d;
    --login-text: #17345f;
    --login-muted: #767676;
    --login-border: #d8d8d8;
    --login-accent: #2db8b1;

    --login-form-width: 430px;

    --login-right:
        max(
            7vw,
            calc((100vw - 1500px) / 2 + 60px)
        );

    margin: 0;

    background: #fff;
}


/* =========================================================
   2. ELEMENTOS QUE NO SE MUESTRAN EN LOGIN
   ========================================================= */

body:has(.account-wrap) .demo-label,
body:has(.account-wrap) .location-bar,
body:has(.account-wrap) .top-actions,
.account-wrap > .eyebrow,
.account-wrap > .callout {
    display: none;
}


/* =========================================================
   3. CABECERA
   ========================================================= */

body:has(.account-wrap) .topbar {
    position: relative;
    z-index: 20;

    display: flex;
    align-items: center;
    justify-content: flex-start;

    min-height: 88px;

    padding:
        8px
        clamp(32px, 5.3vw, 90px);

    background: #fff;

    border: 0;
    border-bottom: 1px solid #ececec;

    box-shadow:
        0 2px 7px rgb(0 0 0 / 10%);
}


/* ---------- Marca ---------- */

body:has(.account-wrap) .brand-group {
    display: flex;
    align-items: center;

    gap: 0;
}

body:has(.account-wrap) .brand {
    display: flex;
    align-items: center;

    gap: 10px;

    color: var(--login-navy);

    text-decoration: none;
}

body:has(.account-wrap) .brand-symbol {
    width: 55px;
    height: 62px;

    flex-shrink: 0;
}

body:has(.account-wrap) .brand-name {
    color: var(--login-navy);

    font-size: 15px;
    line-height: 1.08;
    font-weight: 700;
}

body:has(.account-wrap) .brand small {
    margin-top: 3px;
    padding-left: 0;

    color: #757575;

    border-left: 0;

    font-size: 9px;
    line-height: 1.2;
    font-weight: 400;
}


/* =========================================================
   4. CONTENEDOR GENERAL
   ========================================================= */

body:has(.account-wrap) .app-shell {
    min-height: calc(100svh - 88px);
}

body:has(.account-wrap) .content {
    position: relative;

    width: 100%;
    max-width: none;
    min-height: calc(100svh - 88px);

    margin: 0;
    padding: 0;

    overflow: hidden;

    background: #fff;
}


/* =========================================================
   5. ÁREA DEL LOGIN
   ========================================================= */

.account-wrap {
    position: relative;

    width: 100%;
    max-width: none;
    min-height: calc(100svh - 88px);

    margin: 0;
    padding: 0;

    background: #fff;

    overflow: hidden;
}


/* =========================================================
   6. ILUSTRACIÓN IZQUIERDA
   ========================================================= */

.account-wrap::before {
    content: "";

    position: absolute;

    top: 24px;
    bottom: 0;

    left:
        max(
            5vw,
            calc((100vw - 1500px) / 2 + 60px)
        );

    width: min(52vw, 820px);

    background-image:
        url("../images/brand/comunidades-flashdata.png");

    background-repeat: no-repeat;
    background-position: center top;
    background-size: contain;

    pointer-events: none;
}


/* =========================================================
   7. BLOQUE BIENVENIDA
   ========================================================= */

.account-wrap > h1 {
    position: absolute;

    top: 20%;
    right: var(--login-right);

    width: var(--login-form-width);
    max-width: calc(100% - 40px);

    margin: 0;

    color: var(--login-navy);

    /*
       El texto real del HTML sigue siendo "Bienvenido".
       Visualmente construimos la composición de la referencia.
    */

    font-size: 0;
    line-height: 1;

    z-index: 2;
}


/* ---------- Título ---------- */

.account-wrap > h1::before {
    content: "Bienvenido!";

    display: block;

    color: var(--login-navy);

    font-size: 46px;
    line-height: .98;
    font-weight: 700;

    letter-spacing: -1.6px;
}


/* ---------- Subtítulo ---------- */

.account-wrap > h1::after {
    content: "Finkad\A Software de gesti\F3n de comunidades";

    display: block;

    margin-top: 8px;

    color: var(--login-text);

    white-space: pre-line;

    font-size: 18px;
    line-height: 1.08;
    font-weight: 400;

    letter-spacing: -.3px;
}


/* =========================================================
   8. CONTENEDOR DEL FORMULARIO
   ========================================================= */

.account-wrap > .panel {
    position: absolute;

    top: 41%;
    right: var(--login-right);

    z-index: 2;

    width: var(--login-form-width);
    max-width: calc(100% - 40px);

    margin: 0;
    padding: 0;

    background: transparent;

    border: 0 !important;
    border-radius: 0;

    box-shadow: none !important;

    overflow: visible;
}


/* =========================================================
   9. TEXTO INTRODUCTORIO
   ========================================================= */

.account-wrap .accede {
    margin: 0 0 28px;

    color: var(--login-navy);

    font-size: 14px;
    line-height: 1.4;
    font-weight: 500;
}


/* =========================================================
   10. FORMULARIO
   ========================================================= */

.account-wrap form {
    display: grid;

    grid-template-columns:
        minmax(0, 1fr)
        auto;

    column-gap: 10px;

    align-items: center;

    width: 100%;
}


/* =========================================================
   11. LABELS
   ========================================================= */

.account-wrap .form-label {
    display: block;

    margin: 0 0 6px;

    color: var(--login-muted);

    font-size: 13px;
    line-height: 1.3;
    font-weight: 400;
}


/* =========================================================
   12. EMAIL
   ========================================================= */

.account-wrap label[for="Email"] {
    grid-column: 1 / -1;
    grid-row: 1;
}

.account-wrap #Email {
    grid-column: 1 / -1;
    grid-row: 2;

    margin: 0 0 17px;
}


/* =========================================================
   13. CONTRASEÑA
   ========================================================= */

.account-wrap label[for="Password"] {
    grid-column: 1;
    grid-row: 3;

    margin: 0 0 6px;
}

.account-wrap #Password {
    grid-column: 1 / -1;
    grid-row: 4;

    margin: 0;
}


/* =========================================================
   14. INPUTS
   ========================================================= */

.account-wrap .form-control {
    width: 100%;
    min-height: 40px;

    padding:
        8px
        12px;

    color: #252525;

    background: #fff;

    border: 1px solid var(--login-border);
    border-radius: var(--radius-sm);

    outline: 0;

    box-shadow: none;

    font-size: 14px;
    line-height: 1.4;

    transition:
        border-color 150ms ease,
        box-shadow 150ms ease;
}

.account-wrap .form-control:hover {
    border-color: #bcbcbc;
}

.account-wrap .form-control:focus {
    border-color: var(--login-accent);

    box-shadow:
        0 0 0 3px rgb(45 184 177 / 12%);
}


/* =========================================================
   15. MOSTRAR / OCULTAR CONTRASEÑA
   ========================================================= */

.account-wrap [data-password-toggle="Password"] {
    grid-column: 2;
    grid-row: 3;

    justify-self: end;

    display: inline-flex;
    align-items: center;
    justify-content: flex-end;

    gap: 7px;

    min-height: 0;

    margin: 0 0 6px;
    padding: 0;

    color: #8b8b8b;

    background: transparent;

    border: 0;
    border-radius: 0;

    box-shadow: none;

    font-size: 0;
    line-height: 1;

    cursor: pointer;
}

.account-wrap [data-password-toggle="Password"]:hover {
    color: #555;

    background: transparent;

    border: 0;

    box-shadow: none;
}


/* ---------- Icono de ojo ---------- */

.account-wrap [data-password-toggle="Password"]::before {
    content: "";

    display: block;
    flex-shrink: 0;

    width: 15px;
    height: 11px;

    border: 1.5px solid currentColor;
    border-radius: 75% 15%;

    background:
        radial-gradient(
            circle at center,
            currentColor 0 2px,
            transparent 2.4px
        );

    transform:
        rotate(45deg)
        scale(.85);

    opacity: .85;
}


/* ---------- Texto Mostrar / Ocultar ---------- */

.account-wrap [data-password-toggle="Password"]::after {
    content: "Mostrar";

    font-size: 13px;
    line-height: 1.2;
    font-weight: 400;
}

.account-wrap [data-password-toggle="Password"][aria-pressed="true"]::after {
    content: "Ocultar";
}


/* =========================================================
   16. HE OLVIDADO MI CONTRASEÑA
   ========================================================= */

.account-wrap form > p {
    grid-column: 1 / -1;
    grid-row: 5;

    justify-self: end;

    margin: 7px 0 0;

    font-size: 13px;
    line-height: 1.3;
}

.account-wrap form > p a {
    color: var(--login-navy);

    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 2px;

    transition: color 150ms ease;
}

.account-wrap form > p a:hover {
    color: var(--login-accent);
}


/* =========================================================
   17. BOTÓN ENTRAR
   ========================================================= */

.account-wrap .actions {
    grid-column: 1 / -1;
    grid-row: 6;

    display: block;

    width: 100%;

    margin: 20px 0 0;
}

.account-wrap .actions .btn-primary {
    width: 100%;
    min-height: 44px;

    padding: 9px 20px;

    color: #fff;

    background: var(--brand);

    border: 1px solid var(--brand);
    border-radius: var(--radius-sm);

    box-shadow: none;

    font-size: 15px;
    line-height: 1.2;
    font-weight: 600;

    transition:
        background-color 150ms ease,
        border-color 150ms ease,
        box-shadow 150ms ease;
}

.account-wrap .actions .btn-primary:hover,
.account-wrap .actions .btn-primary:focus-visible {
    color: #fff;

    background: var(--brand-dark);

    border-color: var(--brand-dark);
}

.account-wrap .actions .btn-primary:focus-visible {
    outline: 3px solid var(--focus);
    outline-offset: 2px;
}

.account-wrap .actions .btn-primary:active {
    box-shadow: none;
}


/* =========================================================
   18. ELEMENTOS DUPLICADOS DEL PANEL
   ========================================================= */

.account-wrap .panel > p:not(.accede) {
    display: none;
}


/* =========================================================
   19. FOOTER DEL LOGIN
   ========================================================= */

body:has(.account-wrap) .page-footer {
    position: absolute;

    right: var(--login-right);
    bottom: 9%;

    z-index: 10;

    display: block;

    width: var(--login-form-width);
    max-width: calc(100% - 40px);

    margin: 0;
    padding: 0;

    color: var(--login-navy);

    background: transparent;

    border: 0;
}


/* ---------- Contenido footer ---------- */

body:has(.account-wrap) .page-footer .footer-ownership {
    display: flex;
    flex-direction: row;
    align-items: center;
    flex-wrap: nowrap;

    gap: 12px;

    color: var(--login-navy);

    font-size: 10px;
    line-height: 1.3;
}


/* ---------- Marca FlashData ---------- */

body:has(.account-wrap) .page-footer .flashdata-brand {
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;

    padding: 6px 10px;

    background: #111b32;

    border-radius: var(--radius-sm);
}

body:has(.account-wrap) .page-footer .flashdata-logo {
    display: block;

    width: 105px;
    max-width: none;
    height: auto;
}

body:has(.account-wrap) .page-footer .footer-demo {
    display: none;
}


/* =========================================================
   20. PANTALLAS INTERMEDIAS
   ========================================================= */

@media (max-width: 1200px) {

    body:has(.account-wrap) {
        --login-form-width: 390px;

        --login-right: 5vw;
    }

    .account-wrap::before {
        left: 3vw;

        width: 55vw;
    }

    .account-wrap > h1::before {
        font-size: 40px;
    }

    .account-wrap > h1::after {
        font-size: 17px;
    }
}


/* =========================================================
   21. TABLET
   ========================================================= */

@media (max-width: 1000px) {

    body:has(.account-wrap) {
        --login-form-width: 500px;
    }


    /* ---------- Contenedor ---------- */

    body:has(.account-wrap) .content {
        min-height: calc(100svh - 88px);

        overflow: visible;
    }

    .account-wrap {
        display: flex;
        flex-direction: column;

        align-items: center;
        justify-content: center;

        min-height: calc(100svh - 88px);

        padding:
            60px
            24px
            120px;

        overflow: visible;
    }


    /* ---------- Ilustración (recortada, encima del título) ---------- */

    .account-wrap::before {
        position: static;

        flex-shrink: 0;

        width: min(100%, var(--login-form-width));
        height: 260px;

        margin: 0 0 32px;

        background-size: cover;
        background-position: center 8%;

        border-radius: var(--radius-md);
    }


    /* ---------- Título ---------- */

    .account-wrap > h1 {
        position: static;

        width: min(
            100%,
            var(--login-form-width)
        );
        max-width: none;

        margin: 0 0 48px;
    }

    .account-wrap > h1::before {
        font-size: 42px;
    }

    .account-wrap > h1::after {
        font-size: 18px;
    }


    /* ---------- Formulario ---------- */

    .account-wrap > .panel {
        position: static;

        width: min(
            100%,
            var(--login-form-width)
        );
        max-width: none;
    }


    /* ---------- Footer ---------- */

    body:has(.account-wrap) .page-footer {
        position: static;

        width: min(
            calc(100% - 48px),
            var(--login-form-width)
        );
        max-width: none;

        margin:
            -90px
            auto
            40px;
    }
}


/* =========================================================
   22. MÓVIL
   ========================================================= */

@media (max-width: 600px) {

    body:has(.account-wrap) {
        --login-form-width: 100%;
    }


    /* ---------- Cabecera ---------- */

    body:has(.account-wrap) .topbar {
        min-height: 76px;

        padding:
            7px
            20px;
    }

    body:has(.account-wrap) .brand-symbol {
        width: 46px;
        height: 52px;
    }

    body:has(.account-wrap) .brand-name {
        font-size: 13px;
    }

    body:has(.account-wrap) .brand small {
        font-size: 8px;
    }


    /* ---------- Página ---------- */

    body:has(.account-wrap) .app-shell,
    body:has(.account-wrap) .content {
        min-height: calc(100svh - 76px);
    }

    .account-wrap::before {
        width: 100%;
        height: 200px;

        margin-bottom: 28px;
    }

    .account-wrap {
        min-height: calc(100svh - 76px);

        align-items: stretch;
        justify-content: flex-start;

        padding:
            46px
            22px
            120px;
    }


    /* ---------- Título ---------- */

    .account-wrap > h1 {
        width: 100%;

        margin-bottom: 42px;
    }

    .account-wrap > h1::before {
        font-size: 36px;

        letter-spacing: -1px;
    }

    .account-wrap > h1::after {
        margin-top: 9px;

        font-size: 16px;
        line-height: 1.15;
    }


    /* ---------- Formulario ---------- */

    .account-wrap > .panel {
        width: 100%;
    }

    .account-wrap .accede {
        margin-bottom: 25px;

        font-size: 13px;
    }


    /* ---------- Inputs ---------- */

    .account-wrap .form-control {
        min-height: 44px;
    }


    /* ---------- Footer ---------- */

    body:has(.account-wrap) .page-footer {
        width: calc(100% - 44px);

        margin:
            -80px
            22px
            32px;
    }

    body:has(.account-wrap) .page-footer .footer-ownership {
        flex-wrap: wrap;

        gap: 8px 12px;
    }
}


/* =========================================================
   23. PANTALLAS MUY PEQUEÑAS
   ========================================================= */

@media (max-width: 380px) {

    .account-wrap {
        padding-right: 16px;
        padding-left: 16px;
    }

    .account-wrap > h1::before {
        font-size: 32px;
    }

    .account-wrap > h1::after {
        font-size: 15px;
    }

    body:has(.account-wrap) .page-footer {
        width: calc(100% - 32px);

        margin-right: 16px;
        margin-left: 16px;
    }
}

/* =========================================================
   DASHBOARD - PRÓXIMAS JUNTAS
   ========================================================= */


/* =========================================================
   1. TARJETA
   ========================================================= */

.dashboard-meetings-card {
    min-width: 0;

    overflow: hidden;
}

.dashboard-meetings-header {
    min-height: 58px;
}

.dashboard-meetings-header a {
    font-size: .85rem;

    text-decoration: none;
}


/* =========================================================
   2. DISTRIBUCIÓN
   ========================================================= */

.dashboard-meetings-layout {
    display: grid;

    grid-template-columns:
        minmax(0, 1.5fr)
        minmax(245px, .9fr);

    min-width: 0;

    border-top: 1px solid var(--line);
}


/* =========================================================
   3. LISTADO
   ========================================================= */

.dashboard-meetings-list {
    min-width: 0;
}


/* =========================================================
   4. FILA DE JUNTA
   ========================================================= */

.dashboard-meeting-row {
    display: grid;

    grid-template-columns:
        62px
        minmax(0, 1fr)
        auto
        28px;

    align-items: center;

    gap: 14px;

    min-height: 94px;

    padding:
        12px
        16px;

    margin: 0;

    border-bottom:
        1px solid
        var(--line);
}

.dashboard-meeting-row:last-child {
    border-bottom: 0;
}


/* =========================================================
   5. FECHA
   ========================================================= */

.meeting-date {
    display: flex;
    flex-direction: column;

    align-items: center;
    justify-content: center;

    width: 58px;
    height: 64px;

    background: #f2f7fb;

    border-radius: var(--radius-sm);

    color: var(--brand-dark);

    line-height: 1;
}

.meeting-date strong {
    margin-bottom: 6px;

    font-size: 1.3rem;
    line-height: 1;
    font-weight: 700;
}

.meeting-date span {
    font-size: .72rem;
    line-height: 1;
    font-weight: 600;
}


/* =========================================================
   6. INFORMACIÓN
   ========================================================= */

.meeting-info {
    min-width: 0;
}

.meeting-time {
    display: block;

    margin-bottom: 1px;

    color: var(--muted);

    font-size: .72rem;
    line-height: 1.3;
    font-weight: 600;
}

.meeting-info h3 {
    margin: 0;

    font-size: .9rem;
    line-height: 1.25;
    font-weight: 700;
}

.meeting-info h3 a {
    display: block;

    overflow: hidden;

    color: var(--ink);

    text-decoration: none;

    text-overflow: ellipsis;
    white-space: nowrap;
}

.meeting-info h3 a:hover {
    color: var(--brand);
}

.meeting-community {
    display: block;

    margin-top: 2px;

    overflow: hidden;

    color: var(--muted);

    font-size: .76rem;
    line-height: 1.3;

    text-overflow: ellipsis;
    white-space: nowrap;
}


/* =========================================================
   7. ESTADO
   ========================================================= */

.meeting-status {
    display: flex;

    align-items: center;
    justify-content: flex-end;
}

.meeting-status .badge {
    padding:
        6px
        10px;

    border-radius: 999px;

    font-size: .68rem;
    line-height: 1;
    font-weight: 600;

    white-space: nowrap;
}


/* =========================================================
   8. FLECHA
   ========================================================= */

.meeting-arrow {
    display: grid;

    place-items: center;

    width: 28px;
    height: 36px;

    color: var(--brand);

    text-decoration: none;

    border-radius: var(--radius-sm);

    font-size: 1.1rem;
}

.meeting-arrow:hover {
    color: var(--brand-dark);

    background: var(--soft);
}


/* =========================================================
   9. CALENDARIO
   ========================================================= */

.dashboard-calendar {
    min-width: 0;

    padding:
        18px
        18px
        16px;

    background: #fff;

    border-left:
        1px solid
        var(--line);
}


/* =========================================================
   10. CABECERA CALENDARIO
   ========================================================= */

.dashboard-calendar-header {
    display: flex;

    align-items: center;
    justify-content: space-between;

    margin-bottom: 14px;
}

.dashboard-calendar-header strong {
    color: var(--ink);

    font-size: .85rem;
    line-height: 1.3;
    font-weight: 700;

    text-transform: capitalize;
}


/* =========================================================
   11. DÍAS DE LA SEMANA
   ========================================================= */

.dashboard-calendar-weekdays {
    display: grid;

    grid-template-columns:
        repeat(7, minmax(0, 1fr));

    margin-bottom: 4px;
}

.dashboard-calendar-weekdays span {
    display: grid;

    place-items: center;

    height: 25px;

    color: #637b97;

    font-size: .62rem;
    line-height: 1;
    font-weight: 700;
}


/* =========================================================
   12. GRID DEL CALENDARIO
   ========================================================= */

.dashboard-calendar-grid {
    display: grid;

    grid-template-columns:
        repeat(7, minmax(0, 1fr));

    row-gap: 2px;
}


/* =========================================================
   13. DÍAS
   ========================================================= */

.calendar-day {
    position: relative;

    display: grid;

    place-items: center;

    width: 29px;
    height: 29px;

    justify-self: center;

    color: #47617f;

    border-radius: 50%;

    font-size: .67rem;
    line-height: 1;
    font-weight: 500;
}

.calendar-day-empty {
    visibility: hidden;
}


/* =========================================================
   14. DÍA CON JUNTA
   ========================================================= */

.calendar-day.has-meeting {
    color: var(--brand);

    background: #e8f5fb;

    font-weight: 700;
}


/* =========================================================
   15. JUNTA SELECCIONADA
   ========================================================= */

.calendar-day.is-selected {
    color: #fff;

    background: var(--brand);

    font-weight: 700;

    box-shadow:
        0 4px 10px
        rgb(5 103 158 / 20%);
}


/* =========================================================
   16. DÍA DE HOY
   ========================================================= */

.calendar-day.is-today:not(.is-selected) {
    border:
        1px solid
        var(--brand);
}


/* =========================================================
   17. PRÓXIMA JUNTA BAJO EL CALENDARIO
   ========================================================= */

.calendar-next-meeting {
    position: relative;

    display: flex;
    flex-direction: column;

    margin-top: 18px;
    padding:
        12px
        34px
        12px
        16px;

    color: var(--ink);

    background: #f7fafc;

    border-left:
        3px solid
        var(--brand);

    border-radius:
        0
        var(--radius-sm)
        var(--radius-sm)
        0;

    text-decoration: none;
}

.calendar-next-meeting:hover {
    color: var(--ink);

    background: var(--soft);
}

.calendar-next-date {
    margin-bottom: 3px;

    color: var(--muted);

    font-size: .65rem;
    line-height: 1.2;
    font-weight: 600;
}

.calendar-next-meeting strong {
    overflow: hidden;

    font-size: .75rem;
    line-height: 1.3;

    text-overflow: ellipsis;
    white-space: nowrap;
}

.calendar-next-meeting > span:not(
    .calendar-next-date,
    .calendar-next-arrow
) {
    margin-top: 2px;

    color: var(--muted);

    font-size: .68rem;
    line-height: 1.2;
}

.calendar-next-arrow {
    position: absolute;

    top: 50%;
    right: 12px;

    color: var(--brand);

    font-size: 1rem;

    transform:
        translateY(-50%);
}


/* =========================================================
   18. SIN JUNTAS
   ========================================================= */

.dashboard-meetings-empty {
    padding: 24px;
}

.dashboard-meetings-empty p {
    margin:
        0
        0
        3px;

    color: var(--ink);

    font-weight: 600;
}

.dashboard-meetings-empty span {
    color: var(--muted);

    font-size: .8rem;
}


/* =========================================================
   19. RESPONSIVE
   ========================================================= */

@media (max-width: 1250px) {

    .dashboard-meetings-layout {
        grid-template-columns: 1fr;
    }

    .dashboard-calendar {
        border-top:
            1px solid
            var(--line);

        border-left: 0;
    }

    .dashboard-calendar-header,
    .dashboard-calendar-weekdays,
    .dashboard-calendar-grid,
    .calendar-next-meeting {
        width: 100%;
        max-width: 320px;

        margin-right: auto;
        margin-left: auto;
    }

    .calendar-next-meeting {
        margin-top: 18px;
    }

}


@media (max-width: 720px) {

    .dashboard-meeting-row {
        grid-template-columns:
            54px
            minmax(0, 1fr)
            28px;

        gap: 10px;

        padding:
            14px
            16px;
    }

    .meeting-date {
        width: 50px;
        height: 58px;
    }

    .meeting-status {
        grid-column: 2;
        grid-row: 2;

        justify-content: flex-start;
    }

    .meeting-arrow {
        grid-column: 3;
        grid-row: 1 / span 2;
    }

    .dashboard-calendar {
        padding:
            20px
            16px;
    }

}

/* Dashboard: comunidades y próximas juntas en dos columnas en escritorio */
.dashboard-columns { grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); align-items: stretch; }
.dashboard-columns .dashboard-meetings-layout { grid-template-columns: minmax(0, 1.45fr) minmax(235px, 1fr); }
.dashboard-columns .dashboard-meeting-row { grid-template-columns: 58px minmax(0, 1fr) auto 28px; }
.dashboard-columns .dashboard-meeting-row .meeting-info h3 a { white-space: normal; }
@media (min-width: 1001px) and (max-width: 1200px) {
    .dashboard-columns .dashboard-meetings-layout { grid-template-columns: 1fr; }
    .dashboard-columns .dashboard-calendar { border-left: 0; border-top: 1px solid var(--line); }
    .dashboard-columns .dashboard-calendar-header,.dashboard-columns .dashboard-calendar-weekdays,.dashboard-columns .dashboard-calendar-grid { width: 100%; max-width: 320px; margin-right: auto; margin-left: auto; }
}
@media (max-width: 1000px) { .dashboard-columns { grid-template-columns: 1fr; } }


.community-type-icon {
    display: grid;
    place-items: center;

    width: 42px;
    height: 42px;

    flex-shrink: 0;

    color: #15678d;
    background: #eaf6f7;

    border: 1px solid #d2e8eb;
    border-radius: 50%;
}

.community-type-icon svg {
    width: 20px;
    height: 20px;

    stroke-width: 1.7;
}

.community-type-icon.ordinaria {
    color: #15678d;
    background: #e8f5f7;
}

.community-type-icon.subcomunidad {
    color: #5a65a8;
    background: #eff0fb;
}

.community-type-icon.agrupacion {
    color: #3b806c;
    background: #eaf7f1;
}

/* Dashboard: trabajo pendiente como lista, hermana de "Tus comunidades" */
.dashboard-community { transition: background-color .18s ease; }
.dashboard-community:hover { background: var(--soft); }
.dashboard-community .row-arrow { transition: transform .18s ease; }
.dashboard-community:hover .row-arrow { transform: translateX(2px); }
.community-type-icon.task { color: #15678d; background: #e8f5f7; }
.community-type-icon.task > .brand-icon { width: 30px; height: 30px; }
.dashboard-community-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 4px; }
.dashboard-task { min-width: 0; }
.dashboard-task .task-main { flex: 1 1 auto; min-width: 0; }
.dashboard-task .task-main strong { display: block; color: var(--ink); }
.dashboard-task .task-date { padding: 4px 10px; color: var(--brand-dark); background: var(--soft); border-radius: var(--radius-sm); font-size: .8rem; font-weight: 700; letter-spacing: .03em; white-space: nowrap; }
.dashboard-task .task-owner { display: flex; align-items: center; gap: 8px; min-width: 150px; color: var(--muted); font-size: .9rem; }
.dashboard-task .task-avatar { display: grid; place-items: center; width: 28px; height: 28px; flex-shrink: 0; color: #5a65a8; background: #eff0fb; border-radius: 50%; font-size: .7rem; font-weight: 700; }
@media (max-width: 720px) {
    .dashboard-task { flex-wrap: wrap; row-gap: 8px; }
    .dashboard-task .task-main { flex: 1 1 calc(100% - 110px); }
    .dashboard-task .row-arrow { order: 2; }
    .dashboard-task .task-date, .dashboard-task .task-owner { order: 3; margin-left: 58px; min-width: 0; }
}

/* Dashboard: las dos tarjetas de la fila miden lo mismo */
.dashboard-columns > .card { margin-bottom: 0; }
.dashboard-columns > .dashboard-meetings-card { display: flex; flex-direction: column; }
.dashboard-columns > .dashboard-meetings-card .dashboard-meetings-layout { flex: 1 1 auto; }

/* =========================================================
   DASHBOARD - REFINAMIENTO VISUAL
   ========================================================= */

body[data-view="/Dashboard"] {
    background: linear-gradient(180deg, #f4f7fa 0%, #eef3f7 100%) fixed;
    overflow-x: clip;
}

/* Cabecera más compacta */
body[data-view="/Dashboard"] .page-heading { align-items: center; margin-bottom: 20px; }
body[data-view="/Dashboard"] .page-heading p:last-child { margin-bottom: 0; }

/* Tarjetas: menos borde, más sombra suave y esquinas más redondeadas */
body[data-view="/Dashboard"] .dashboard-metrics .card,
body[data-view="/Dashboard"] .dashboard-columns > .card,
body[data-view="/Dashboard"] #tareas-pendientes {
    background: rgb(255 255 255 / 94%);
    border: 1px solid #dce8ec;
    border-radius: var(--radius-lg);
    box-shadow: 0 4px 18px rgb(16 55 78 / 5%);
}

body[data-view="/Dashboard"] #tareas-pendientes { overflow: hidden; }

/* Métricas */
body[data-view="/Dashboard"] .metric-card {
    position: relative;
    min-height: 128px;
    overflow: hidden;
    background: #fff;
    transition: transform .18s ease;
}

body[data-view="/Dashboard"] .metric-card:hover {
    transform: translateY(-2px);
    background: #fff;
}

body[data-view="/Dashboard"] .metric-card strong {
    color: #0b315b;
    font-size: 2.15rem;
    font-weight: 700;
    line-height: 1.1;
}

body[data-view="/Dashboard"] .metric-card > .brand-icon { position: relative; z-index: 1; }

/* The line icons sit directly on the card, without the previous radial halo. */
body[data-view="/Dashboard"] .metric-card::before { content: none; }

/* Cabeceras de bloque */
body[data-view="/Dashboard"] .card-header { padding: 24px 28px 20px; }

body[data-view="/Dashboard"] .card-header > a {
    padding: 6px 14px;
    color: var(--brand);
    background: var(--soft);
    border: 1px solid #cfe6e8;
    border-radius: 999px;
    font-size: .85rem;
    font-weight: 600;
    text-decoration: none;
    transition: background-color .18s ease, border-color .18s ease;
}

body[data-view="/Dashboard"] .card-header > a:not(.dashboard-see-all):hover { background: #d8eef0; border-color: #b5dadd; }
.dashboard-columns #comunidades .card-header > a.dashboard-see-all {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 0;
    color: var(--brand);
    background: transparent;
    border: 0;
    border-radius: 0;
    font-size: .9rem;
    font-weight: 600;
    text-decoration: none;
}
.dashboard-columns #comunidades .card-header > a.dashboard-see-all:hover { color: var(--brand-dark); text-decoration: underline; }
.dashboard-see-all span { transition: transform .16s ease; }
.dashboard-see-all:hover span { transform: translateX(3px); }

/* Filas: hover con un toque turquesa */
body[data-view="/Dashboard"] .dashboard-community:hover { background: #f1f9fa; }
body[data-view="/Dashboard"] .dashboard-community:hover .row-arrow { color: var(--accent-dark); }

/* Calendario */
body[data-view="/Dashboard"] .dashboard-calendar { background: #fbfdff; }
body[data-view="/Dashboard"] .calendar-day.has-meeting { background: var(--brand); color: #fff; }

/* Banda de cabecera: un único degradado marino a todo el ancho */
body[data-view="/Dashboard"] .dashboard-hero {
    position: relative;
    isolation: isolate;
    margin: -34px 0 32px;
    padding: 40px 0 36px;
}
body[data-view="/Dashboard"] .dashboard-hero::before {
    content: "";
    position: absolute;
    z-index: -1;
    top: 0; bottom: 0;
    left: 50%;
    width: 100vw;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #0a2540 0%, #0d3358 100%);
    border-bottom: 3px solid #2cbeb8;
}
body[data-view="/Dashboard"] .dashboard-hero .page-heading { margin-bottom: 28px; }
body[data-view="/Dashboard"] .dashboard-hero .page-heading h1 { color: #fff; }
body[data-view="/Dashboard"] .dashboard-hero .page-heading p { color: #b9cde0; }
body[data-view="/Dashboard"] .dashboard-hero .eyebrow { color: #5fd6cf; }
body[data-view="/Dashboard"] .dashboard-hero .page-heading > a {
    background: transparent; color: #fff; border: 1px solid rgb(255 255 255 / 45%);
}
body[data-view="/Dashboard"] .dashboard-hero .page-heading > a:hover { background: rgb(255 255 255 / 12%); }
body[data-view="/Dashboard"] .dashboard-hero .metric-card { border-color: transparent; box-shadow: 0 10px 28px rgb(0 0 0 / 22%); }
body[data-view="/Dashboard"] .dashboard-hero .page-heading + .dashboard-metrics { margin-bottom: 0; }
body[data-view="/Dashboard"] .dashboard-hero .dashboard-metrics { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
body[data-view="/Dashboard"] .dashboard-hero .metric-card,
body[data-view="/Dashboard"] .dashboard-hero .metric-card:hover {
    min-height: 132px;
    padding: 16px;
    align-items: center;
    gap: 12px;
    background: #fff;
    border-color: #dce8ec;
    box-shadow: 0 4px 18px rgb(16 55 78 / 8%);
}
body[data-view="/Dashboard"] .dashboard-hero .metric-card { color: var(--ink); }
body[data-view="/Dashboard"] .dashboard-hero .metric-card > .brand-icon { width: 68px; height: 58px; flex: 0 0 68px; }
body[data-view="/Dashboard"] .dashboard-hero .metric-card > div { min-width: 0; }
body[data-view="/Dashboard"] .dashboard-hero .metric-label { color: #6c7d8c; font-size: 14px; line-height: 1.2; }
body[data-view="/Dashboard"] .dashboard-hero .metric-card strong { font-size: 1.5rem; line-height: 1.2; }
body[data-view="/Dashboard"] .dashboard-hero .metric-card small { font-size: 14px; line-height: 1.25; }

.dashboard-activity { margin-top: 24px; }
.dashboard-activity-heading { margin-bottom: 12px; }
.dashboard-activity-heading h2 { margin: 0 0 4px; color: var(--brand-dark);  font-weight: 700; }
.dashboard-activity-heading p { margin: 0; color: var(--muted); font-size: 14px; }
.dashboard-activity-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.activity-card { min-width: 0; min-height: 150px; padding: 16px 18px; }
.activity-card h3 { margin: 0 0 12px; color: var(--brand-dark); font-weight: 700; }
.community-status-chart { display: flex; align-items: center; justify-content: space-around; gap: 12px; }
.activity-donut { display: block; width: 124px; height: 124px; flex: 0 0 124px; overflow: visible; }
.activity-donut circle { fill: none; stroke-width: 8; transform: rotate(-90deg); transform-origin: 50% 50%; }
.activity-donut-track { stroke: #e7eff2; }
.activity-donut-active { stroke: #2cbeb8; stroke-linecap: round; }
.activity-donut-review { stroke: #0d3358; stroke-linecap: round; }
.activity-donut-other { stroke: #94a6b4; stroke-linecap: round; }
.activity-donut-number { fill: #173b5b; font-size: 22px; font-weight: 700; }
.activity-donut-caption { fill: #708493; font-size: 11.5px; }
.activity-legend { display: grid; gap: 7px; margin: 0; padding: 0; list-style: none; color: #617483; font-size: 14px; }
.activity-legend li { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.activity-legend li strong { color: #6b7f8d; font-size: 14px; }
.activity-legend-label { display: inline-flex; align-items: center; gap: 6px; min-width: 0; }
.activity-legend-dot { width: 7px; height: 7px; flex: 0 0 7px; border-radius: 50%; background: #2cbeb8; }
.activity-legend-dot.review { background: #0d3358; }
.activity-legend-dot.other { background: #94a6b4; }
.activity-legend-dot.pending { background: transparent; border: 1px solid #aebdc7; }
.task-completion-summary { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; color: #657986; font-size: 14px; }
.task-completion-summary strong { color: #687e8b; font-weight: 600; }
.activity-progress,.property-community-track { height: 5px; overflow: hidden; border-radius: 999px; background: #e7eff2; }
.activity-progress { margin: 12px 0; }
.activity-progress span,.property-community-track span { display: block; height: 100%; border-radius: inherit; background: #2cbeb8; transition: width .2s ease; }
.task-legend { gap: 5px; }
.property-community-chart { display: grid; gap: 9px; }
.property-community-label { display: flex; justify-content: space-between; gap: 10px; margin-bottom: 3px; color: #687e8b; font-size: 14px; }
.property-community-label strong { font-size: 14px; }
.property-community-track { height: 5px; }
.property-community-track span { background: #0d3358; }

@media (max-width: 1000px) {
    body[data-view="/Dashboard"] .dashboard-hero .dashboard-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .dashboard-activity-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .activity-card:last-child { grid-column: 1 / -1; }
}
@media (max-width: 600px) {
    body[data-view="/Dashboard"] .dashboard-hero .dashboard-metrics { grid-template-columns: 1fr 1fr; gap: 9px; }
    body[data-view="/Dashboard"] .dashboard-hero .metric-card,
    body[data-view="/Dashboard"] .dashboard-hero .metric-card:hover { min-height: 138px; padding: 10px; gap: 8px; flex-direction: column; align-items: flex-start; }
    body[data-view="/Dashboard"] .dashboard-hero .metric-card > .brand-icon { width: 68px; height: 56px; flex-basis: 56px; }
    .dashboard-activity-grid { grid-template-columns: 1fr; }
    .activity-card:last-child { grid-column: auto; }
    .community-status-chart { justify-content: flex-start; gap: 20px; }
}

/* =========================================================
   MIS COMUNIDADES - tarjetas y barra de herramientas
   ========================================================= */
body:has(.communities-page) { background: linear-gradient(180deg, #f4f7fa 0%, #eef3f7 100%) fixed; }

.communities-toolbar {
    display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px;
    margin-bottom: 22px; padding: 14px 16px;
    background: #fff; border: 1px solid #dce7eb; border-radius: var(--radius-lg);
    box-shadow: 0 4px 16px rgb(16 55 78 / 5%);
}
.communities-search { position: relative; flex: 1 1 280px; max-width: 460px; }
.communities-search svg { position: absolute; top: 50%; left: 14px; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.communities-search .form-control { padding-left: 42px; border-color: #cfdce2; }
.communities-count { color: var(--muted); font-weight: 600; margin-left: auto; }
.communities-filters { display: flex; flex-wrap: wrap; gap: 6px; }
.communities-filters a {
    padding: 7px 14px; border: 1px solid #dce7eb; border-radius: 999px;
    color: var(--brand-dark); background: #fff; font-weight: 600; font-size: .9rem; text-decoration: none;
    transition: background-color .16s ease, border-color .16s ease;
}
.communities-filters a:hover { background: var(--soft); border-color: #bddde3; }
.communities-filters a[aria-current] { background: var(--brand-dark); border-color: var(--brand-dark); color: #fff; }

.community-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; align-items: stretch; }
.community-tile {
    display: flex; flex-direction: column; align-items: flex-start; gap: 14px;
    padding: 20px; min-width: 0;
    background: #fff; border: 1px solid #dce7eb; border-radius: var(--radius-lg);
    box-shadow: 0 4px 16px rgb(16 55 78 / 5%);
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.community-tile:hover,
.community-tile:focus-within { transform: translateY(-2px); border-color: #a9d6dc; box-shadow: 0 10px 26px rgb(16 55 78 / 9%); }
.community-tile-head { display: flex; gap: 14px; align-items: flex-start; width: 100%; min-width: 0; }
.community-tile-title { min-width: 0; }
.community-tile-type { margin: 0 0 2px; font-size: .78rem; font-weight: 600; color: var(--muted); }
.community-tile h2 { margin: 0 0 4px; font-size: 1.1rem; line-height: 1.3; font-weight: 700; }
.community-tile h2 a { color: var(--brand-dark); text-decoration: none; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.community-tile h2 a:hover { text-decoration: underline; }
.community-tile-address { margin: 0; font-size: .86rem; line-height: 1.4; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.community-status {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    width: fit-content;
    max-width: 100%;
    padding: 4px 11px;
    color: #526777;
    background: #eef2f5;
    border: 1px solid transparent;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.25;
}
.community-status::before { content: ""; width: 7px; height: 7px; flex: 0 0 7px; border-radius: 50%; background: currentColor; }
.community-status.is-active { color: #1f7a54; background: #e8f6ef; }
.community-status.is-review { color: #a65a0b; background: #fff3e2; }
.community-status.is-inactive { color: #8a3d48; background: #fff0f1; }
.community-status.is-preparing,.community-status.is-neutral { color: #526777; background: #eef2f5; }
.community-tile .community-status { margin-top: 10px; }

.community-tile-count { display: flex; align-items: center; gap: 9px; width: 100%; margin: 0; padding-top: 14px; border-top: 1px solid #e6eef1; color: var(--ink); font-size: .9rem; }
.community-tile-count svg { color: #15678d; flex-shrink: 0; }

.community-tile .community-card-actions {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;

    width: 100%;
    margin-top: auto;
}

.community-tile .community-card-actions .btn {
    flex: 0 0 160px;
    width: 160px;
}
.community-tile .community-card-actions .btn:first-child {
    flex: 0 0 170px;
    width: 170px;
}

.community-tile .community-card-actions .btn:last-child {
    flex: 0 0 130px;
    width: 130px;
}

@media (max-width: 520px) {
    .community-tile .community-card-actions {
        flex-direction: column;
        align-items: flex-start;
    }

    .community-tile .community-card-actions .btn {
        flex: 0 0 auto;
        width: 160px;
    }
}

.community-open, .community-summary {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    min-height: 40px; padding: 0 12px; border-radius: var(--radius-sm); font-weight: 600; font-size: .9rem; text-decoration: none; white-space: nowrap;
    transition: background-color .16s ease, border-color .16s ease;
}
.community-open { flex: 1 1 auto; background: var(--brand); color: #fff; border: 1px solid var(--brand); }
.community-open:hover { background: var(--brand-dark); border-color: var(--brand-dark); color: #fff; }
.community-summary { background: #fff; color: var(--brand); border: 1px solid #cfdce2; }
.community-summary:hover { background: var(--soft); border-color: #a9c4d0; }
.community-open:focus-visible, .community-summary:focus-visible, .communities-filters a:focus-visible { outline: 3px solid #2cbeb8; outline-offset: 2px; }

@media (max-width: 1399px) { .community-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 1099px) { .community-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) {
    .community-grid { grid-template-columns: 1fr; }
    .communities-count { margin-left: 0; }
    .community-tile .community-card-actions > * { flex: 1 1 50%; }
}

.community-tile .community-type-icon { width: 52px; height: 52px; }
.community-tile .community-type-icon svg { width: 26px; height: 26px; }
@media (max-width: 640px) {
    .community-tile .community-card-actions { flex-direction: column; }
    .community-tile .community-card-actions > * { flex: 0 0 auto; width: 100%; }
}

.communities-page .page-heading { align-items: center; margin-bottom: 24px; }
.communities-page .page-heading p:last-child { margin-bottom: 0; }
.communities-page .communities-toolbar { gap: 10px 12px; margin-bottom: 16px; }
.communities-page .communities-search { display: flex; flex: 1 1 520px; flex-wrap: nowrap; align-items: center; gap: 8px; max-width: 620px; min-width: min(100%, 280px); margin: 0; }
.communities-page .communities-search-field { position: relative; flex: 1 1 auto; min-width: 0; }
.communities-page .communities-search-field svg { position: absolute; top: 50%; left: 14px; z-index: 1; display: block; transform: translateY(-50%); color: #607482; pointer-events: none; }
.communities-page .communities-search .form-control { display: block; width: 100%; min-width: 0; min-height: 48px; padding: 10px 14px 10px 42px; font-size: 14px; }
.communities-page .communities-search .btn { align-self: center; flex: 0 0 auto; min-height: 42px; margin: 0; padding: 7px 13px; font-size: 14px; white-space: nowrap; }
.communities-page .communities-count { font-size: 14px; white-space: nowrap; }
.communities-page .communities-filters a { padding: 6px 11px; font-size: 14px; }
.community-view-toggle { display: inline-flex; gap: 3px; padding: 3px; border: 1px solid #dce7eb; border-radius: var(--radius-sm); background: #f7f9fb; }
.community-view-toggle button {
    display: grid;
    place-items: center;
    width: 36px;
    height: 34px;
    padding: 6px;
    color: #607482;
    background: transparent;
    border: 0;
    border-radius: var(--radius-sm);
}
.community-view-toggle button svg { width: 20px; height: 20px; }
.community-view-toggle button[aria-pressed="true"] { color: #fff; background: var(--brand-dark); }
.community-view-toggle button:focus-visible { outline-offset: 1px; }
.community-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.community-tile { gap: 10px; padding: 12px; }
.community-tile-head { gap: 9px; }
.community-tile .community-type-icon { width: 40px; height: 40px; }
.community-tile .community-type-icon svg { width: 21px; height: 21px; }
.community-tile-type { font-size: 14px; }
.community-tile h2 { font-size: 1rem; }
.community-tile-address { font-size: 14px; overflow-wrap: anywhere; }
.community-tile .community-status { margin-top: 8px; }
.community-tile-count { gap: 7px; padding-top: 10px; font-size: 14px; }
.community-tile-count svg { width: 15px; height: 15px; }
.community-tile .community-card-actions { gap: 6px; }
.community-tile .community-open,
.community-tile .community-summary {
    min-height: 38px;
    padding: 4px 9px;
    font-size: 14px;
    white-space: normal;
}
.community-tile .community-open { flex: 1 1 120px; }
.community-tile .community-summary { flex: 1 1 90px; }
.community-grid[data-layout="list"] { grid-template-columns: 1fr; gap: 10px; }
.community-grid[data-layout="list"] .community-tile {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto 300px;
    align-items: center;
    gap: 16px;
    padding: 12px 16px;
}
.community-grid[data-layout="list"] .community-tile-count { width: auto; margin: 0; padding: 0 0 0 14px; border-top: 0; border-left: 1px solid #e6eef1; }
.community-grid[data-layout="list"] .community-tile .community-status { margin-top: 0; }
.community-grid[data-layout="list"] .community-tile .community-card-actions {
    display: grid;
    grid-template-columns: minmax(164px, 1.15fr) minmax(132px, .9fr);
    align-items: center;
    gap: 8px;
    width: 300px;
    margin-top: 0;
}
.community-grid[data-layout="list"] .community-tile .community-open,
.community-grid[data-layout="list"] .community-tile .community-summary { width: 100%; min-width: 0; }

@media (max-width: 900px) {
    .community-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .communities-page .communities-toolbar { align-items: center; }
    .communities-page .communities-search { flex-basis: 100%; max-width: none; }
    .communities-page .communities-count { margin-left: 0; }
    .community-grid[data-layout="list"] .community-tile { grid-template-columns: minmax(0, 1fr) 300px; }
    .community-grid[data-layout="list"] .community-tile-head { grid-column: 1; }
    .community-grid[data-layout="list"] .community-tile-count { grid-column: 1; grid-row: 2; width: auto; min-width: 0; padding: 10px 0 0; border-top: 1px solid #e6eef1; border-left: 0; }
    .community-grid[data-layout="list"] .community-tile .community-card-actions { grid-column: 2; grid-row: 1 / span 2; }
}
@media (max-width: 640px) {
    .community-grid { grid-template-columns: 1fr; }
    .communities-page .page-heading { align-items: flex-start; flex-direction: column; }
    .communities-page .communities-toolbar { align-items: flex-start; }
    .communities-page .communities-filters { order: 4; }
    .communities-page .communities-search { flex-basis: 100%; min-width: 0; }
    .community-grid[data-layout="list"] .community-tile { grid-template-columns: minmax(0, 1fr); }
    .community-grid[data-layout="list"] .community-tile-head,
    .community-grid[data-layout="list"] .community-tile-count,
    .community-grid[data-layout="list"] .community-tile .community-card-actions { grid-column: 1; grid-row: auto; }
    .community-grid[data-layout="list"] .community-tile .community-card-actions { width: 100%; grid-template-columns: minmax(0, 1.15fr) minmax(0, .9fr); }
}

@media (prefers-reduced-motion: reduce) {
    .community-tile, .dashboard-see-all span { transition: none; }
}

/* Cabeceras de bloque unificadas en el Dashboard */
.dashboard-columns > .card > .card-header {
    box-sizing: border-box;
    align-items: center;
    height: 72px;
    padding-top: 0;
    padding-bottom: 0;
    border-bottom: 1px solid var(--line);
}

.dashboard-columns > .dashboard-meetings-card .dashboard-meetings-layout { border-top: 0; }

/* Títulos de fila del Dashboard: mismo peso ligero y elegante */
body[data-view="/Dashboard"] .dashboard-community strong,
body[data-view="/Dashboard"] .dashboard-task .task-main strong,
body[data-view="/Dashboard"] .meeting-info h3,
body[data-view="/Dashboard"] .meeting-info h3 a { font-weight: 500; }

body[data-view] .meeting-calendar .calendar-day.has-meeting { background: var(--brand); color: #fff; }
body[data-view] .meeting-calendar .calendar-nav { font-size: 24px; }
body[data-view] .meeting-calendar .calendar-day.has-meeting.is-past { background: #e7ecf1; color: #5b6b7a; }

.dashboard-split { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; align-items: start; margin-bottom: 20px; }
.dashboard-split > .card { margin: 0; min-width: 0; }
.dashboard-split .dashboard-task { flex-wrap: wrap; row-gap: 4px; }
.dashboard-notice { display: flex; align-items: center; gap: 12px; }
.dashboard-notice .notice-main { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.dashboard-notice .notice-main strong { font-weight: 500; }
.dashboard-notice .notice-main small { color: var(--muted); }
@media (max-width: 1000px) { .dashboard-split { grid-template-columns: 1fr; } }

/* Enlaces de cabecera unificados (Ver más / Ver todas) */
.card-header > a.dashboard-see-all {
    display: inline-flex; align-items: center; gap: 5px; padding: 4px 0; color: var(--brand);
    background: transparent; border: 0; border-radius: 0; font-size: .9rem; font-weight: 600; text-decoration: none; white-space: nowrap;
}
.card-header > a.dashboard-see-all:hover { color: var(--brand-dark); text-decoration: underline; background: transparent; }

/* Trabajo pendiente + Avisos: misma altura y cabecera alineada */
.dashboard-split { align-items: stretch; }
.dashboard-split > .card { display: flex; flex-direction: column; height: 100%; }
.dashboard-split > .card > .card-header { box-sizing: border-box; height: 72px; padding-top: 0; padding-bottom: 0; align-items: center; border-bottom: 1px solid var(--line); }
.dashboard-split .dashboard-task { flex-wrap: nowrap; align-items: center; gap: 12px; }
.dashboard-split .dashboard-task .task-owner { flex: 0 0 140px; width: 140px; min-width: 0; }
.dashboard-split .dashboard-task .task-owner:not(:has(.task-avatar)) { visibility: hidden; }
.task-owner { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.dashboard-task .task-owner { overflow: hidden; }
.dashboard-task .task-owner > :not(.task-avatar) { min-width: 0; }
.dashboard-task .task-main small, .dashboard-task .task-main strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: block; }
.dashboard-split .dashboard-task .row-arrow { flex: 0 0 auto; }
@media (max-width: 1000px) { .dashboard-split .dashboard-task .task-owner { display: none; } }

/* Icono de avisos */
.notice-icon { display: grid; place-items: center; flex: 0 0 auto; width: 40px; height: 40px; border-radius: 50%; background: #e6f7f6; color: var(--accent-dark); }
.notice-icon svg { width: 20px; height: 20px; }
.notice-icon.is-important { background: #fff3e2; color: #a65a0b; }
body[data-view] .card-header > a.dashboard-see-all { padding: 4px 0; background: transparent; border: 0; border-radius: 0; font-size: .9rem; }
body[data-view] .card-header > a.dashboard-see-all:hover { background: transparent; color: var(--brand-dark); text-decoration: underline; }
body[data-view] .dashboard-see-all span { transition: transform .16s ease; }

/* Fila de junta clicable en toda su superficie */
.dashboard-meeting-row { position: relative; cursor: pointer; }
.dashboard-meeting-row h3 a::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.dashboard-meeting-row .meeting-arrow { position: relative; z-index: 2; }
.dashboard-meeting-row h3 a:focus-visible { outline: none; }
.dashboard-meeting-row:has(h3 a:focus-visible) { outline: 3px solid var(--focus); outline-offset: -3px; }
.dashboard-meeting-row { transition: background-color .15s ease; }
.dashboard-meeting-row:hover { background: #f1f9fa; }
.dashboard-meeting-row:hover .meeting-arrow { color: var(--accent-dark); transform: translateX(2px); }

.brand-icon.brand-icon-elementos,
.community-sidebar .brand-icon.brand-icon-elementos { width: 34px; height: 34px; margin: 0; }

/* Desplegables: picker personalizable donde el navegador lo soporta (Chrome/Edge 135+) */
.form-select { transition: border-color .15s ease, box-shadow .15s ease; }
.form-select:hover { border-color: var(--brand); }
.form-select:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(11, 79, 120, .14); }
@supports (appearance: base-select) {
    select.form-select:not([multiple]),
    select.form-select:not([multiple])::picker(select) { appearance: base-select; }
    select.form-select:not([multiple]) { display: flex; align-items: center; gap: 12px; padding-inline: 13px; background-image: none; cursor: pointer; }
    select.form-select:not([multiple])::picker-icon {
        content: ""; width: 9px; height: 9px; flex-shrink: 0; margin-left: auto; margin-top: -4px;
        border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
        transform: rotate(45deg); color: var(--muted); transition: transform .18s ease, margin .18s ease;
    }
    select.form-select:not([multiple]):open::picker-icon { transform: rotate(225deg); margin-top: 4px; color: var(--brand); }
    select.form-select:not([multiple])::picker(select) {
        margin-top: 6px; padding: 6px; max-height: 320px; overflow-y: auto;
        border: 1px solid var(--line); border-radius: var(--radius-md); background: #fff;
        box-shadow: 0 12px 32px rgba(16, 42, 67, .14), 0 2px 6px rgba(16, 42, 67, .06);
        opacity: 0; translate: 0 -4px;
        transition: opacity .16s ease, translate .16s ease, overlay .16s allow-discrete, display .16s allow-discrete;
    }
    select.form-select:not([multiple]):open::picker(select) { opacity: 1; translate: 0 0; }
    @starting-style { select.form-select:not([multiple]):open::picker(select) { opacity: 0; translate: 0 -4px; } }
    select.form-select:not([multiple]) option {
        display: flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: var(--radius-sm);
        font-size: 14px; color: var(--ink); cursor: pointer;
    }
    select.form-select:not([multiple]) option:hover,
    select.form-select:not([multiple]) option:focus-visible { background: var(--soft); color: var(--brand-dark); outline: none; }
    select.form-select:not([multiple]) option:checked { background: var(--brand); color: #fff; font-weight: 600; }
    select.form-select:not([multiple]) option::checkmark { content: "✓"; order: 1; margin-left: auto; font-size: 12px; }
    select.form-select:not([multiple]) option:not(:checked)::checkmark { visibility: hidden; }
    select.form-select:not([multiple]) option:disabled { color: var(--muted); cursor: default; }
}

/* Gastos: listado compacto y ayuda accesible sin acordeones. */
.economy-section-heading, .economy-record-heading { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.economy-section-heading { justify-content: space-between; margin-bottom: 14px; }
.economy-section-heading h3 { margin: 0; }
.economy-view-switch { display: flex; gap: 6px; }
.economy-view-switch [aria-current] { background: var(--brand); color: #fff; border-color: var(--brand); }
.economy-payment-search { display: flex; flex-direction: row; flex-wrap: wrap; align-items: end; gap: 12px; padding: 16px; }
.economy-payment-search > div { flex: 1 1 260px; }
.economy-payment-search .form-label { font-size: .85rem; }
.economy-payment-search > a { font-size: .8rem; padding: 10px 0; }
.economy-payment-grid, .economy-record-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-items: start; }
.economy-payment-grid.is-list { grid-template-columns: minmax(0, 1fr); }
.economy-record-grid > :only-child, .economy-payment-grid > :only-child { grid-column: 1 / -1; }
.economy-charges tbody td:first-child { min-width: 150px; }
.economy-charges tbody td:nth-child(5), .economy-charges tbody td:nth-child(6) { white-space: nowrap; }
.economy-payment-card, .economy-adjustment-card, .economy-management-card { padding: 18px; min-width: 0; font-size: .9rem; }
.economy-record-heading h4 { margin: 0; font-size: .95rem; line-height: 1.5; font-weight: 500; flex: 1; }
.economy-record-amount { font-size: .9rem; font-weight: 500; white-space: nowrap; font-variant-numeric: tabular-nums; }
.economy-payment-date { display: block; font-size: .85rem; font-weight: 500; color: var(--brand); margin: 8px 0; }
.economy-record-note { font-size: .8rem; color: var(--muted); }
.economy-payment-balance { display: flex; justify-content: space-between; gap: 8px; padding: 10px 0; margin: 0; border-top: 1px solid var(--line); font-size: .8rem; }
.economy-payment-balance strong { font-weight: 500; white-space: nowrap; }
.economy-application-list { list-style: none; padding: 0; margin: 0; font-size: .8rem; }
.economy-application-list li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px; padding: 8px 0; border-top: 1px solid var(--line); }
.economy-application-list strong { font-weight: 400; }
.economy-application-list .economy-record-note { flex-basis: 100%; }
.economy-pagination { font-size: .85rem; margin: 16px 0 24px; }
.economy-form-grid { display: grid; gap: 16px; align-items: start; margin: 24px 0; }
.economy-form-grid > .panel { margin: 0; min-width: 0; padding: 18px; }
.economy-form-grid h3 { font-size: .95rem; line-height: 1.5; }
.economy-form-grid .form-label, .economy-form-grid .form-check-label { font-size: .8rem; }
.economy-form-grid .form-control, .economy-form-grid .form-select { font-size: .9rem; min-width: 0; }
.economy-form-grid legend { font-size: .9rem; }
.economy-form-grid-payments { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.economy-form-grid-debt { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.economy-form-grid-repartos { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.economy-form-grid-repartos { border-top: 1px solid var(--line); padding-top: 24px; margin-top: 8px; }
/* Shared expense detail and action dialog. */
.expense-detail-dialog { width: min(900px, calc(100% - 32px)); max-height: calc(100dvh - 32px); overflow-y: auto; padding: 24px; }
.expense-detail-dialog h2 { font-size: 1.15rem; margin: 0; }
.expense-detail-dialog .expense-detail { margin: 20px 0 0; font-size: .9rem; }
.expense-detail-heading { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; }
.expense-detail-heading .eyebrow { font-size: .72rem; letter-spacing: .03em; color: var(--muted); margin-bottom: 6px; }
.expense-detail-heading h3 { font-size: 1.1rem; margin: 0; line-height: 1.4; }
.expense-detail-total { white-space: nowrap; font-size: 1.2rem; font-weight: 500; color: var(--brand-dark); }
.expense-detail-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin: 14px 0 22px; font-size: .82rem; color: var(--muted); }
.expense-detail-meta time { font-weight: 500; color: var(--ink); margin-left: 6px; }
.expense-detail-origin { padding: 14px 16px; border-left: 3px solid var(--brand); border-radius: 8px; background: var(--canvas); margin: 0 0 20px; }
.expense-detail-origin p { margin: 6px 0; }
.expense-detail-sections { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.expense-detail-sections > section { border: 1px solid var(--line); border-radius: 12px; padding: 16px; min-width: 0; }
.expense-detail-sections h4 { font-size: .9rem; font-weight: 500; margin: 0 0 8px; }
.expense-detail-subtotal { font-weight: 500; margin-bottom: 12px; }
.expense-detail-subtotal span { font-size: .78rem; color: var(--muted); font-weight: 400; }
.expense-detail-items { list-style: none; padding: 0; margin: 0; }
.expense-detail-items li { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); font-size: .82rem; }
.expense-detail-items strong { font-weight: 500; white-space: nowrap; }
.expense-detail-items small { display: block; color: var(--muted); }
.expense-detail-history { margin-top: 20px; border-top: 1px solid var(--line); padding-top: 16px; font-size: .82rem; }
.expense-detail-history summary { cursor: pointer; font-weight: 500; }
.expense-detail-history summary span { color: var(--muted); font-weight: 400; }
.expense-detail-history ul { padding-left: 20px; margin: 14px 0 0; color: var(--muted); }
.expense-detail-history li { padding-bottom: 10px; }
.expense-detail-dialog .expense-modal-form { margin: 24px 0 0; padding: 20px; border: 1px solid var(--line); border-top: 3px solid var(--brand); border-radius: 12px; box-shadow: none; font-size: .85rem; }
.expense-modal-form h3 { font-size: 1rem; margin-bottom: 12px; }
.expense-modal-form form .actions { margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line); }
.expense-modal-form .form-label { margin-top: 12px; }
.expense-modal-form .form-control, .expense-modal-form .form-select { font-size: .85rem; }
.expense-create-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 16px; }
.expense-create-fields > div { min-width: 0; }
.expense-create-name { grid-column: 1 / -1; }
.expense-modal-form .expense-create-fields .form-label { margin: 0 0 6px; }
.expense-create-fields .form-control, .expense-create-fields .form-select { margin-bottom: 0; }
@media (max-width: 640px) { .expense-create-fields { grid-template-columns: minmax(0, 1fr); } }
.expense-detail[data-expense-status="Previsto"] .badge-state { background: #fff5d9; color: #805611; }
.expense-detail[data-expense-status="Aprobado"] .badge-state { background: #e8f3fc; color: #075783; }
.expense-detail[data-expense-status="Realizado"] .badge-state { background: #e8f5ee; color: #22654f; }
@media (max-width: 640px) {
    .expense-detail-dialog { padding: 18px; }
    .expense-detail-heading { flex-direction: column; gap: 10px; }
    .expense-detail-sections { grid-template-columns: minmax(0, 1fr); }
    .expense-detail-dialog .expense-modal-form { padding: 16px; }
}
.economy-form-grid-repartos > :only-child { grid-column: 1 / -1; }
.economy-payment-grid.has-compact-rows, .economy-form-grid-debt.has-compact-rows { grid-auto-rows: 1px; row-gap: 0; }
.economy-form-grid form:has(> input[value="reverseAdjustment"]) > button { margin-top: 16px; }
.economy-record-section { margin: 24px 0; }
.economy-adjustment-card { border-left: 4px solid var(--brand); }
.economy-adjustment-label { margin: 8px 0; color: var(--brand); font-size: .8rem; font-weight: 500; }
.economy-adjustment-card time { color: var(--muted); font-size: .8rem; }
.economy-adjustment-card p, .economy-management-card p { margin: 8px 0; }
.economy-document-button { align-self: start; min-height: 44px; font-size: .75rem; }
.economy-management-status { color: var(--brand); font-size: .85rem; font-weight: 500; }
.economy-record-details { display: grid; grid-template-columns: minmax(90px, auto) minmax(0, 1fr); gap: 6px 12px; margin: 12px 0; font-size: .8rem; }
.economy-record-details dt { color: var(--muted); font-weight: 500; }
.economy-history { list-style: none; margin: 20px 0 28px; padding: 0 0 0 24px; border-left: 2px solid var(--line); }
.economy-history-entry { position: relative; margin: 0 0 16px; }
.economy-history-dot { position: absolute; left: -31px; top: 24px; width: 12px; height: 12px; border-radius: 50%; background: var(--brand); border: 3px solid var(--canvas); box-sizing: content-box; }
.economy-history-entry .card { padding: 18px; }
.economy-history h3 { font-size: .95rem; font-weight: 500; margin: 0 0 6px; }
.economy-history time { font-size: .8rem; color: var(--brand); }
.economy-history-actor { font-size: .85rem; margin: 8px 0 4px; }
.economy-history-detail { font-size: .9rem; margin: 10px 0 0; white-space: pre-wrap; }
@media (min-width: 1600px) { .economy-payment-grid:not(.is-list) { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 1199px) { .economy-form-grid-payments { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 900px) {
    .economy-payment-grid, .economy-record-grid, .economy-form-grid-debt, .economy-form-grid-payments, .economy-form-grid-repartos { grid-template-columns: minmax(0, 1fr); }
}
.economy-offer, .economy-allocation { padding: 20px; }
.economy-offer-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.economy-offer h3, .economy-allocation h3 { display: flex; align-items: baseline; gap: 8px; font-size: .9rem; line-height: 1.5; font-weight: 500; margin: 0; }
.economy-offer-amount { font-size: .9rem; font-weight: 500; white-space: nowrap; font-variant-numeric: tabular-nums; }
.economy-offer-supplier { color: var(--muted); font-size: .85rem; margin: 6px 0 12px; }
.economy-offer-conditions { font-size: .9rem; margin: 0 0 14px; }
.economy-offer-no-document { color: var(--muted); font-size: .8rem; margin: 0; }
.economy-offer-documents { margin: 0; }
.economy-offer-documents .minutes-attachment { flex-wrap: wrap; }
.economy-offer-documents .minutes-attachment-info { min-width: 120px; }
.economy-offer-documents .minutes-attachment-info strong { white-space: normal; overflow-wrap: anywhere; font-weight: 500; }
.economy-offer-documents .btn { min-height: 44px; font-size: .75rem; }
.economy-allocation > p { font-size: .85rem; color: var(--muted); margin: 8px 0 0; }
@media (min-width: 1600px) {
    .operation-area:has(> .economy-allocation) {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        align-items: start;
        gap: 16px;
    }
    .operation-area:has(> .economy-allocation) > .callout,
    .operation-area:has(> .economy-allocation) > .economy-form-grid { grid-column: 1 / -1; }
    .operation-area:has(> .economy-allocation) > .economy-allocation { margin: 0; min-width: 0; }
    .operation-area:has(> .economy-allocation) > .economy-allocation:only-of-type { grid-column: 1 / -1; }
}
@media (max-width: 540px) {
    .economy-offer-heading { flex-wrap: wrap; gap: 8px; }
    .economy-offer, .economy-allocation { padding: 16px; }
    .economy-offer-documents .btn { margin-left: 48px; }
}
.expense-row { padding: 1rem 1.25rem; border-bottom: 1px solid var(--tblr-border-color, #dce5eb); }
.expense-row:last-child { border-bottom: 0; }
.expense-actions { display: flex; flex-wrap: wrap; gap: .5rem 1rem; }
.expense-action { display: inline-flex; align-items: center; gap: .25rem; max-width: 100%; }
.expense-help { position: relative; display: inline-flex; }
.expense-help-button { min-width: 44px; min-height: 44px; border-radius: 50%; }
.expense-help-text { display: none; position: absolute; z-index: 20; bottom: 100%; right: 0; width: 260px; max-width: calc(100vw - 3rem); padding: .75rem; border: 1px solid #52677c; border-radius: .5rem; background: #fff; color: #182e43; box-shadow: 0 3px 12px #0002; font-size: .95rem; font-weight: normal; }
.expense-help:not([data-dismissed]):hover .expense-help-text,
.expense-help:not([data-dismissed]):focus-within .expense-help-text,
.expense-help[data-open] .expense-help-text { display: block; }
/* Gastos: filtros compactos, lectura por filas y estados diferenciados. */
.expense-filters { padding: 18px 20px; }
.expense-filters .form-label { font-size: .85rem; font-weight: 500; margin-bottom: 6px; }
.expense-filters .form-control, .expense-filters .form-select { font-size: .9rem; min-height: 44px; }
.expense-filters .actions { gap: 8px 12px; margin-top: 0; }
.expense-filters .actions > a { font-size: .85rem; }
.expense-results-count { font-size: .85rem; color: var(--muted); }
.expense-list { border: 1px solid var(--line); border-radius: var(--radius-md); }
.expense-row { padding: 18px 20px; font-size: .9rem; border-color: var(--line); }
.expense-row { background: #fff; }
.expense-row:first-child { border-radius: 11px 11px 0 0; }
.expense-row:last-child { border-radius: 0 0 11px 11px; }
.expense-row:only-child { border-radius: 11px; }
.expense-row h3 { font-size: .9rem; line-height: 1.5; font-weight: 500; }
.expense-row h3 a { display: inline-flex; align-items: baseline; gap: 8px; color: var(--ink); text-decoration: none; }
.expense-row h3 a:hover { color: var(--brand); text-decoration: underline; }
.expense-number { padding: 1px 6px; border: 1px solid var(--line); border-radius: 5px; color: var(--muted); background: #fff; font-size: .75rem; font-weight: 500; flex-shrink: 0; }
.expense-date { color: var(--muted); font-size: .85rem; }
.expense-amount { font-size: .9rem; font-variant-numeric: tabular-nums; white-space: nowrap; }
.expense-amount strong { font-weight: 500; }
.expense-row small, .expense-row > p { font-size: .8rem; color: var(--muted); }
.expense-row .badge-state { display: inline-flex; align-items: center; gap: 6px; font-size: .75rem; font-weight: 500; padding: 4px 9px; border: 1px solid transparent; }
.expense-row .badge-state::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; flex-shrink: 0; }
.expense-row[data-expense-status="Previsto"] .badge-state { color: #735414; background: #fff5da; border-color: #ebdcb4; }
.expense-row[data-expense-status="Aprobado"] .badge-state { color: #075783; background: #e9f3fa; border-color: #c9dfed; }
.expense-row[data-expense-status="Realizado"] .badge-state { color: #25634e; background: #eaf5ef; border-color: #cce3d6; }
.expense-row .expense-actions { gap: 6px 12px; align-items: center; }
.expense-row .expense-actions .btn { font-size: .75rem; min-height: 44px; padding: 7px 12px; }
.expense-row .expense-help-button {
    position: relative; width: 44px; height: 44px; padding: 0; border: 0;
    border-radius: 50%; box-shadow: none; color: var(--muted);
    background: radial-gradient(circle, #e7eff5 0 11px, transparent 12px);
    font-size: .75rem;
}
.expense-row .expense-help-button:hover, .expense-row .expense-help-button:focus-visible { color: var(--brand); background: radial-gradient(circle, #d8e8f3 0 11px, transparent 12px); }
.expense-row .expense-help-button:focus-visible { outline: 2px solid var(--brand); outline-offset: 1px; }
.expense-row .expense-help-text { font-size: .8rem; line-height: 1.5; text-align: left; }
@media (min-width: 768px) {
    .expense-filters .row > :first-child { flex: 1 1 40%; width: auto; }
    .expense-filters .row > :nth-child(2) { flex: 0 1 175px; width: auto; }
    .expense-filters .row > .actions { flex: 0 0 auto; width: auto; }
}
@media (max-width: 767px) {
    .expense-row .expense-date, .expense-row .expense-amount { flex: 0 0 auto; width: auto; }
    .expense-filters { padding: 16px; }
    .expense-row { padding: 16px; }
}
@media (max-width: 575px) {
    .expense-help-text { position: fixed; left: 1rem; right: 1rem; bottom: 1rem; width: auto; max-width: none; }
}

/* Titularidades de la ficha del inmueble: tarjetas independientes, sin alterar otras listas. */
.panel:has(> form input[name="action"][value="owner"]) > p {
    margin-bottom: 16px;
}
.panel:has(> form input[name="action"][value="owner"]) > .list-row {
    margin: 0;
    padding: 18px 20px;
    gap: 20px;
    border: 1px solid #cbdfea;
    border-left: 4px solid #7daac4;
    border-radius: var(--radius-md);
    background: #eef6fc;
}
.panel:has(> form input[name="action"][value="owner"]) > .list-row + .list-row,
.panel:has(> form input[name="action"][value="owner"]) > .list-row + form {
    margin-top: 16px;
}
.panel:has(> form input[name="action"][value="owner"]) > .list-row > p {
    min-width: 0;
    margin: 0;
    color: var(--ink);
    font-weight: 500;
    line-height: 1.65;
}
.panel:has(> form input[name="action"][value="owner"]) > .list-row > form {
    flex-shrink: 0;
    margin: 0;
}
.panel:has(> form input[name="action"][value="owner"]) > .list-row .btn {
    min-height: 44px;
    background: var(--paper);
}
.panel:has(> form input[name="action"][value="owner"]) > .list-row .btn:hover {
    color: var(--brand-dark);
    background: #dfedf7;
}
@media (max-width: 720px) {
    .panel:has(> form input[name="action"][value="owner"]) > .list-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
        padding: 16px;
    }
}

.minutes-signature-gallery { display: flex; flex-wrap: wrap; gap: 20px; margin-top: 16px; }
.minutes-signature { flex: 0 1 240px; min-width: 0; margin: 0; padding: 16px; border: 1px solid var(--line); border-radius: 12px; background: white; }
.minutes-signature svg { display: block; width: 100%; height: 84px; color: var(--ink); }
.minutes-signature figcaption { border-top: 1px solid var(--line); padding-top: 10px; }
.minutes-signature figcaption strong, .minutes-signature small { display: block; font-size: .8rem; }
.minutes-signature small { color: var(--muted); }
.minutes-sign-review { border: 1px solid var(--line); border-radius: 12px; padding: 0 14px; }
.minutes-sign-review > div { max-height: 180px; overflow-y: auto; padding-bottom: 14px; font-size: .85rem; }
.minutes-signatures-section { margin-top: 28px !important; padding-top: 20px !important; }
.minutes-signatures-section > strong { display: block; font-size: .95rem; font-weight: 600; color: var(--ink); }
.minutes-signature-gallery .minutes-signature { flex-basis: 300px; padding: 20px; background: #fff; border-color: #dfe3e8; }
.minutes-signature-gallery .minutes-signature svg { height: 110px; }
.minutes-signature-status { display: block; margin-top: 6px; color: var(--muted); font-size: .78rem; }
.minutes-signing-card .minutes-signing-actions, .minutes-signing-card .minute-sign-form { display: flex; flex-direction: column; align-items: stretch; gap: 12px; }
.minutes-signing-card .minute-sign-form .form-select { width: 100%; max-width: 100%; }
.minutes-signing-card .minute-sign-form .hint { margin: 0; }
.minutes-signing-card .minute-sign-form .actions { margin-top: 6px; }
.minutes-signing-card .minute-send-form { border-top: 1px solid var(--line); padding-top: 18px; margin-top: 8px; }

/* Finkad: identidad original aportada, sin modificar los iconos del producto. */
.topbar a.brand { display: flex; flex-direction: column; align-items: flex-start; gap: 0; min-width: 0; }
.topbar .brand .finkad-logo { display: block; width: 184px; max-width: 100%; height: auto; flex-shrink: 0; overflow: hidden; }
.topbar .brand > small { margin-top: 0; font-size: 11px; line-height: 1; padding-left: 6px; }
body:has(.account-wrap) .topbar .brand .finkad-logo { width: 250px; }
@media (max-width: 720px) {
    .topbar .brand .finkad-logo { width: 168px; }
    body:has(.account-wrap) .topbar .brand .finkad-logo { width: 210px; }
}

/* Iconos lineales Finkad: lámina vectorial sin rótulos ni recortes raster. */
.brand-icon.brand-icon-line { width: 28px; height: 28px; color: var(--brand); mix-blend-mode: normal; }
.community-sidebar .brand-icon.brand-icon-line, .side-nav .brand-icon.brand-icon-line { width: 24px; height: 24px; }
.top-actions .brand-icon.brand-icon-line { width: 24px; height: 24px; }
.metric-card > .brand-icon.brand-icon-line { width: 44px; height: 44px; flex-basis: 44px; }
.topbar .brand > small { display: none; }

body[data-view="/Dashboard"] .dashboard-hero .metric-card > .brand-icon.brand-icon-line { width: 48px; height: 48px; flex: 0 0 48px; filter: none; box-shadow: none; }
@media (max-width:720px) {
    body[data-view="/Dashboard"] .dashboard-hero .metric-card > .brand-icon.brand-icon-line { width: 48px; height: 48px; flex: 0 0 48px; }
}

/* Compatibilidad con la vista ya cargada en el servidor: descarga solo dentro de Asistencia. */
body[data-view="/Juntas/Detalle"] #main > .attendance-export { display: none; }

.minutes-version-header { gap: 1rem; flex-wrap: wrap; }
.minutes-pdf-download { flex-shrink: 0; margin-left: auto; }

/* Minutes: shared hierarchy for editor preview, saved versions and signature review. */
.minutes-formatted-text { color: var(--text, #24445a); overflow-wrap: anywhere; font-size: 0.9375rem; line-height: 1.65; }
.minutes-formatted-text p { margin: 0 0 0.5rem; white-space: pre-wrap; }
.minutes-formatted-text .minutes-text-title { font-size: 1.25rem; line-height: 1.4; margin-bottom: 1rem; color: var(--brand-dark, #075783); }
.minutes-formatted-text .minutes-text-metadata { margin-bottom: 0.375rem; }
.minutes-formatted-text .minutes-text-section { margin: 1.5rem 0 0.875rem; padding: 0.625rem 0.75rem; border-left: 3px solid #00b5c1; background: #eff8fa; border-radius: 0 6px 6px 0; font-size: 1rem; font-weight: 700; color: var(--brand-dark, #075783); }
.minutes-formatted-text .minutes-text-ballot { margin: 1.5rem 0 0.75rem; padding-top: 1rem; border-top: 1px solid #dce5e9; color: var(--brand-dark, #075783); }
.minutes-preview-tools { display: flex; align-items: center; flex-wrap: wrap; gap: 0.75rem; margin: 0.5rem 0 0.875rem; }
.minutes-editor-preview { border: 1px solid #cddce3; border-radius: 10px; padding: 1.25rem; max-height: 36rem; overflow: auto; background: #fff; }
.minutes-editor-preview[hidden], #minutes[hidden] { display: none; }

.minutes-text-space { height: 0.375rem; }

/* Shared gallery/list selector: same line icons, labels, sizing and selected state. */
.view-mode-switch:is(.community-view-toggle, .economy-view-switch) {
    display: inline-flex; align-items: center; gap: 4px; padding: 4px;
    border: 1px solid #dce7eb; border-radius: 10px; background: #f7f9fb; flex-shrink: 0;
}
.view-mode-switch:is(.community-view-toggle, .economy-view-switch) > :is(a, button) {
    display: inline-flex; align-items: center; justify-content: center; gap: 7px;
    width: auto; height: auto; min-height: 38px; padding: 7px 11px; margin: 0;
    border: 1px solid transparent; border-radius: 7px; background: transparent;
    color: #506777; box-shadow: none; font-size: 14px; font-weight: 500;
    line-height: 1.25; text-decoration: none; white-space: nowrap;
}
.view-mode-switch > :is(a, button) svg { width: 18px; height: 18px; flex: 0 0 18px; }
.view-mode-switch:is(.community-view-toggle, .economy-view-switch) > :is(a, button):hover { background: #e8f1f4; color: var(--brand-dark); }
.view-mode-switch:is(.community-view-toggle, .economy-view-switch) > :is([aria-current="page"], [aria-pressed="true"]) { background: var(--brand-dark); color: #fff; }
.view-mode-switch > :is(a, button):focus-visible { outline: 2px solid var(--brand-dark); outline-offset: 2px; }
