@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    --navy: #12304a;
    --navy-deep: #073761;
    --teal: #0f8b78;
    --teal-dark: #087264;
    --gold: #c4922d;
    --ink: #12233d;
    --muted: #66758a;
    --line: #dce4ec;
    --surface: #ffffff;
    --canvas: #f4f7fa;
    --shadow: 0 12px 34px rgba(20, 44, 70, .10);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); font-family: Inter, Arial, sans-serif; background: var(--canvas); }
button, input { font: inherit; }
select, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: #0765cf; text-decoration: none; }

/* Login */
.login-body { min-height: 100vh; background: #fff; }
.login-shell { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(440px, 1fr); min-height: 100vh; }
.login-hero { position: relative; min-height: 100vh; overflow: hidden; color: #fff; background: url('images/municipal-hall.jpg') center / cover no-repeat; }
.hero-overlay { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(4, 38, 68, .94) 0%, rgba(7, 55, 97, .62) 45%, rgba(7, 55, 97, .12) 100%), linear-gradient(0deg, rgba(4, 35, 62, .6), transparent 55%); }
.hero-copy { position: relative; z-index: 1; width: min(680px, calc(100% - 100px)); padding: clamp(70px, 12vh, 150px) 0 0 clamp(38px, 6vw, 90px); }
.eyebrow { display: block; margin-bottom: 18px; color: #a8e8df; font-size: 12px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.hero-copy h1 { margin: 0; max-width: 650px; font-size: clamp(42px, 4.2vw, 70px); line-height: 1.08; letter-spacing: -.04em; text-shadow: 0 3px 16px rgba(0, 0, 0, .22); }
.hero-copy p { max-width: 570px; margin: 26px 0 0; color: rgba(255,255,255,.9); font-size: clamp(16px, 1.3vw, 20px); line-height: 1.75; }
.monument-card { position: absolute; z-index: 2; left: clamp(38px, 6vw, 90px); bottom: clamp(35px, 6vh, 70px); width: clamp(185px, 17vw, 260px); margin: 0; overflow: hidden; border: 3px solid rgba(255,255,255,.9); border-radius: 18px; box-shadow: 0 18px 45px rgba(0,0,0,.28); background: #fff; }
.monument-card img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: center 60%; }
.monument-card figcaption { padding: 10px 12px; color: var(--navy); font-size: 11px; font-weight: 700; text-align: center; }
.login-panel { display: grid; place-items: center; padding: 38px clamp(24px, 4vw, 70px); background: radial-gradient(circle at top right, #eefaf8, transparent 34%), #fff; }
.login-panel-inner { width: min(100%, 570px); text-align: center; }
.brand-mark { display: grid; place-items: center; width: 76px; height: 76px; margin: 0 auto 16px; border: 3px solid #fff; border-radius: 50%; color: #fff; background: linear-gradient(145deg, var(--teal), var(--navy-deep)); box-shadow: 0 0 0 2px var(--gold), 0 8px 18px rgba(9, 70, 90, .2); font-size: 25px; font-weight: 800; letter-spacing: -.04em; }
.login-brand strong { display: block; font-size: clamp(25px, 2.1vw, 35px); letter-spacing: -.025em; }
.login-brand span { display: block; margin-top: 7px; color: var(--teal); font-size: 20px; font-weight: 700; }
.login-brand small { display: block; margin-top: 5px; color: #5b6674; font-size: 14px; }
.login-card { margin-top: 28px; padding: clamp(26px, 3.4vw, 45px); border: 1px solid #e0e7ed; border-radius: 16px; background: rgba(255,255,255,.97); box-shadow: var(--shadow); text-align: left; }
.login-card header { margin-bottom: 28px; text-align: center; }
.login-card h2 { margin: 0; font-size: 31px; letter-spacing: -.03em; }
.login-card header p { margin: 9px 0 0; color: var(--muted); }
.alert { margin: -8px 0 18px; padding: 12px 14px; border: 1px solid #fecaca; border-radius: 9px; color: #9f1239; background: #fff1f2; font-size: 13px; }
.form-field { display: block; margin-bottom: 20px; color: #223149; font-size: 13px; font-weight: 700; }
.input-wrap { display: flex; align-items: center; min-height: 56px; margin-top: 8px; border: 1.5px solid #cdd6df; border-radius: 9px; background: #fff; transition: border-color .2s, box-shadow .2s; }
.input-wrap:focus-within { border-color: var(--teal); box-shadow: 0 0 0 4px rgba(15, 139, 120, .11); }
.field-icon { width: 48px; color: #607083; font-size: 17px; text-align: center; }
.input-wrap input { min-width: 0; flex: 1; height: 52px; border: 0; outline: 0; color: var(--ink); background: transparent; }
.input-wrap input::placeholder { color: #8d99a7; }
.password-toggle { padding: 8px 14px; border: 0; color: var(--teal); background: transparent; cursor: pointer; font-size: 12px; font-weight: 700; }
.form-options { display: flex; justify-content: space-between; gap: 16px; margin: 4px 0 24px; color: #475569; font-size: 13px; }
.form-options label { display: flex; gap: 7px; align-items: center; }
.form-options input { accent-color: var(--teal); }
.form-options a { color: var(--teal); font-weight: 600; }
.btn { min-height: 48px; padding: 0 18px; border: 0; border-radius: 8px; cursor: pointer; font-weight: 700; transition: transform .15s, box-shadow .15s, background .15s; }
.btn:hover { transform: translateY(-1px); }
.btn-primary { color: #fff; background: linear-gradient(135deg, #14a38e, #087c70); box-shadow: 0 8px 18px rgba(15,139,120,.18); }
.btn-primary:hover { background: linear-gradient(135deg, #0f947f, #076b61); }
.btn-outline { border: 1px solid #cbd5e1; color: var(--navy); background: #fff; }
.btn-block { width: 100%; }
.demo-access { margin-top: 16px; padding: 10px; border-radius: 8px; color: #536273; background: #f4f7fa; font-size: 11px; text-align: center; }
.trust-row { display: flex; justify-content: center; align-items: center; gap: 13px; margin-top: 22px; color: #596779; font-size: 12px; }
.trust-row i { width: 5px; height: 5px; border-radius: 50%; background: var(--teal); }
.login-footer { margin: 20px 0 0; color: #8b96a3; font-size: 11px; }
.otp-card header { margin-bottom: 20px; }
.otp-shield { display: grid; width: 48px; height: 48px; margin: -5px auto 13px; place-items: center; border-radius: 50%; color: #fff; background: linear-gradient(145deg, var(--teal), var(--navy-deep)); box-shadow: 0 7px 16px rgba(15,139,120,.22); font-size: 20px; }
.otp-card header strong { color: var(--navy); }
.otp-demo { margin-bottom: 18px; padding: 11px 14px; border: 1px dashed #86cdbf; border-radius: 8px; color: #096d5e; background: #effbf8; font-size: 13px; text-align: center; }
.otp-demo strong { margin-left: 6px; font-size: 19px; letter-spacing: .18em; }
.otp-field { text-align: center; }
.otp-input { display: block; width: 100%; height: 62px; margin-top: 9px; border: 1.5px solid #cdd6df; border-radius: 9px; outline: 0; color: var(--navy); background: #fff; font-size: 28px; font-weight: 800; letter-spacing: .42em; text-align: center; transition: border-color .2s, box-shadow .2s; }
.otp-input:focus { border-color: var(--teal); box-shadow: 0 0 0 4px rgba(15,139,120,.11); }
.otp-input::placeholder { color: #b8c1ca; }
.otp-timer { margin: -8px 0 19px; color: var(--muted); font-size: 12px; text-align: center; }
.otp-timer strong { color: var(--teal); font-variant-numeric: tabular-nums; }
.otp-timer.expired, .otp-timer.expired strong { color: #be123c; }
.resend-form { display: flex; justify-content: center; gap: 6px; align-items: center; margin-top: 19px; color: var(--muted); font-size: 12px; }
.resend-form button { padding: 4px; border: 0; color: var(--teal); background: transparent; cursor: pointer; font-weight: 700; }
.resend-form button:disabled { color: #9ca8b5; cursor: not-allowed; }
.back-login { display: inline-block; margin-top: 15px; color: #64748b; font-size: 12px; font-weight: 600; }

/* Dashboard */
.dashboard-body { min-height: 100vh; background: #f4f7fa; }
.sidebar { position: fixed; z-index: 30; inset: 0 auto 0 0; display: flex; width: 238px; flex-direction: column; color: #fff; background: linear-gradient(180deg, #073761, #042a4d); box-shadow: 8px 0 28px rgba(7,55,97,.12); }
.sidebar-brand { display: flex; gap: 14px; align-items: center; padding: 25px 20px 21px; border-bottom: 1px solid rgba(255,255,255,.09); }
.brand-mark.small { width: 52px; height: 52px; margin: 0; flex: 0 0 auto; font-size: 18px; }
.sidebar-brand strong { font-size: 15px; line-height: 1.35; }
.sidebar nav { padding: 16px 10px; overflow-y: auto; }
.sidebar nav a { display: flex; gap: 13px; align-items: center; margin: 3px 0; padding: 12px 14px; border-radius: 7px; color: rgba(255,255,255,.88); font-size: 13px; font-weight: 600; transition: background .2s, color .2s; }
.sidebar nav a span { width: 20px; font-size: 17px; text-align: center; }
.sidebar nav a:hover, .sidebar nav a.active { color: #fff; background: linear-gradient(90deg, #0e9d8b, #07857a); }
.sidebar-footer { margin-top: auto; padding: 18px 20px 24px; border-top: 1px solid rgba(255,255,255,.16); text-align: center; }
.sidebar-footer small { display: block; color: rgba(255,255,255,.75); font-size: 10px; line-height: 1.6; }
.sidebar-footer a { display: inline-block; margin-top: 11px; padding: 8px 18px; border: 1px solid rgba(255,255,255,.3); border-radius: 6px; color: #fff; font-size: 11px; }
.dashboard-main { min-width: 0; margin-left: 238px; padding: 25px 24px 12px; }
.topbar { display: flex; justify-content: space-between; gap: 26px; align-items: center; margin-bottom: 22px; }
.eyebrow.teal { margin: 0 0 5px; color: var(--teal); font-size: 11px; }
.topbar h1 { margin: 0; font-size: clamp(25px, 2.4vw, 38px); letter-spacing: -.04em; }
.topbar-actions { display: flex; gap: 14px; align-items: center; }
.global-search { display: flex; width: min(33vw, 430px); height: 44px; align-items: center; border: 1px solid #d5dee7; border-radius: 8px; background: #fff; }
.global-search span { padding-left: 13px; }
.global-search input { min-width: 0; flex: 1; height: 100%; padding: 0 12px; border: 0; outline: 0; background: transparent; font-size: 12px; }
.icon-button { position: relative; width: 41px; height: 41px; border: 0; border-radius: 50%; color: var(--navy); background: #fff; cursor: pointer; box-shadow: 0 3px 12px rgba(20,44,70,.09); }
.icon-button b { position: absolute; top: -4px; right: -3px; display: grid; place-items: center; width: 17px; height: 17px; border-radius: 50%; color: #fff; background: var(--teal); font-size: 9px; }
.user-chip { display: flex; gap: 9px; align-items: center; }
.user-chip > span { display: grid; width: 40px; height: 40px; place-items: center; border-radius: 50%; color: #fff; background: var(--teal); font-weight: 800; }
.user-chip div { display: grid; gap: 2px; }
.user-chip strong { font-size: 12px; }
.user-chip small { color: var(--muted); font-size: 9px; }
.stat-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 16px; }
.stat-card { display: flex; min-width: 0; gap: 14px; align-items: center; padding: 20px; border: 1px solid var(--line); border-radius: 10px; background: #fff; box-shadow: 0 5px 15px rgba(20,44,70,.05); }
.stat-icon { display: grid; width: 58px; height: 58px; flex: 0 0 auto; place-items: center; border-radius: 13px; font-size: 25px; }
.stat-card.blue .stat-icon { color: #1565c0; background: #e8f2ff; }
.stat-card.green .stat-icon { color: #07886e; background: #dcf7ee; }
.stat-card.purple .stat-icon { color: #7045cc; background: #f0eaff; }
.stat-card.amber .stat-icon { color: #d98a00; background: #fff2d7; }
.stat-card > div:last-child { min-width: 0; }
.stat-card span { display: block; overflow: hidden; color: #46566c; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.stat-card strong { display: block; margin: 4px 0; font-size: 29px; letter-spacing: -.04em; }
.stat-card small { color: #08926e; font-size: 9px; font-weight: 700; }
.stat-card.amber small { color: #df8300; }
.stat-card em { margin-left: 5px; color: #8a97a5; font-style: normal; font-weight: 400; }
.content-grid { display: grid; grid-template-columns: minmax(0, 1fr) 295px; gap: 16px; }
.panel { border: 1px solid var(--line); border-radius: 10px; background: #fff; box-shadow: 0 5px 15px rgba(20,44,70,.045); }
.panel h2 { margin: 0; font-size: 16px; letter-spacing: -.02em; }
.panel-heading { display: flex; justify-content: space-between; gap: 16px; align-items: center; padding: 16px 17px 11px; }
.panel-heading > a { align-self: flex-end; margin-bottom: 8px; font-size: 11px; }
.tabs { display: flex; margin-top: 12px; }
.tabs button { padding: 8px 13px; border: 1px solid #d9e2ea; border-right: 0; color: #394b61; background: #fff; cursor: pointer; font-size: 10px; }
.tabs button:first-child { border-radius: 5px 0 0 5px; }
.tabs button:last-child { border-right: 1px solid #d9e2ea; border-radius: 0 5px 5px 0; }
.tabs button.active { border-color: var(--teal); color: #067262; background: #effbf9; }
.table-wrap { width: 100%; overflow-x: auto; border-top: 1px solid var(--line); }
table { width: 100%; border-collapse: collapse; font-size: 10px; }
th, td { padding: 11px 10px; border-bottom: 1px solid #e5eaf0; text-align: left; vertical-align: middle; }
th { color: #3b4d62; background: #f8fafc; font-size: 9px; white-space: nowrap; }
td:nth-child(2) { min-width: 190px; line-height: 1.35; }
td:nth-child(5) { min-width: 145px; }
tbody tr:hover { background: #fbfdff; }
.status { display: inline-block; padding: 5px 7px; border-radius: 5px; font-size: 8px; font-weight: 700; white-space: nowrap; }
.status.approved { border: 1px solid #9bdcad; color: #176534; background: #eaf9ee; }
.status.for-review { border: 1px solid #f3c576; color: #9b5900; background: #fff7e5; }
.status.archived { border: 1px solid #cbd3dc; color: #586575; background: #f1f4f7; }
.btn-view { padding: 5px 12px; border: 1px solid #67a8ef; border-radius: 5px; color: #0864c5; background: #fff; cursor: pointer; font-size: 9px; }
.empty-row td { padding: 30px; color: var(--muted); text-align: center; }
.right-column { display: grid; align-content: start; gap: 16px; }
.quick-actions { padding: 17px; }
.quick-actions h2 { margin-bottom: 14px; }
.quick-actions .btn + .btn { margin-top: 10px; }
.quick-actions .btn { font-size: 11px; }
.panel-title { display: flex; justify-content: space-between; padding: 16px; border-bottom: 1px solid var(--line); }
.sessions article { display: flex; gap: 12px; padding: 11px 15px; border-bottom: 1px solid #e6ebf0; }
.sessions time { display: grid; width: 43px; flex: 0 0 auto; overflow: hidden; border: 1px solid #cfe0e5; border-radius: 6px; text-align: center; }
.sessions time b { padding: 3px; color: #fff; background: var(--teal); font-size: 8px; }
.sessions time strong { font-size: 20px; }
.sessions time small { padding-bottom: 3px; font-size: 7px; }
.sessions article div { display: grid; gap: 3px; align-content: center; }
.sessions article div strong { font-size: 10px; }
.sessions article div span, .sessions article div small { color: var(--muted); font-size: 8px; }
.chart-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: 16px; margin-top: 16px; }
.chart-panel, .type-panel { min-height: 230px; padding: 17px; }
.bar-chart { display: flex; height: 160px; gap: 10px; align-items: end; margin-top: 18px; padding-top: 10px; border-bottom: 1px solid #dce4ec; background: repeating-linear-gradient(to bottom, #eef2f6 0 1px, transparent 1px 40px); }
.bar-chart > div { display: flex; height: 100%; flex: 1; flex-direction: column; justify-content: end; align-items: center; }
.bar-chart span { width: min(22px, 72%); min-height: 8px; border-radius: 4px 4px 0 0; background: linear-gradient(#14a38e, #087b70); }
.bar-chart small { margin: 6px 0 -18px; color: #738095; font-size: 7px; }
.type-content { display: flex; gap: 25px; align-items: center; margin-top: 18px; }
.donut { display: grid; width: 150px; height: 150px; flex: 0 0 auto; place-items: center; border-radius: 50%; background: conic-gradient(#7249ce 0 71%, #21a269 71% 84.2%, #187ad2 84.2% 93.7%, #eba51c 93.7% 98.8%, #aab4c1 98.8%); }
.donut::before { width: 82px; height: 82px; border-radius: 50%; background: #fff; content: ''; }
.donut span { position: absolute; display: grid; text-align: center; }
.donut strong { font-size: 19px; }
.donut small { color: var(--muted); font-size: 9px; }
.type-content ul { width: 100%; margin: 0; padding: 0; list-style: none; }
.type-content li { display: flex; gap: 8px; align-items: center; padding: 7px 0; border-bottom: 1px solid #edf0f3; color: #506075; font-size: 9px; }
.type-content li b { margin-left: auto; color: var(--ink); }
.type-content i { width: 9px; height: 9px; border-radius: 50%; }
.purple-dot { background: #7249ce; }.green-dot { background: #21a269; }.blue-dot { background: #187ad2; }.amber-dot { background: #eba51c; }
.dashboard-footer { margin-top: 17px; padding: 12px 4px 2px; color: #7f8c9c; font-size: 9px; }
.mobile-menu, .sidebar-backdrop { display: none; }

/* Application modules */
.notice { margin: 0 0 16px; padding: 13px 16px; border: 1px solid; border-radius: 9px; font-size: 13px; }
.notice-success { border-color: #9bdcad; color: #176534; background: #eaf9ee; }
.notice-error { border-color: #fecaca; color: #9f1239; background: #fff1f2; }
.page-card { padding: 22px; border: 1px solid var(--line); border-radius: 12px; background: #fff; box-shadow: 0 5px 15px rgba(20,44,70,.05); }
.page-card h2 { margin: 0 0 16px; font-size: 20px; }
.section-heading { display: flex; justify-content: space-between; gap: 20px; align-items: flex-start; margin-bottom: 22px; }
.section-heading h2 { margin: 0 0 6px; }
.section-heading p, .muted { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.connection-strip { display: flex; justify-content: flex-end; gap: 12px; align-items: center; margin: -10px 0 14px; font-size: 11px; }
.connection { display: inline-block; padding: 7px 10px; border-radius: 999px; font-size: 10px; font-weight: 800; text-transform: uppercase; }
.connection.online { color: #176534; background: #dcf7e7; }.connection.offline { color: #8a5800; background: #fff1cc; }
.filter-bar { display: grid; grid-template-columns: 2fr repeat(3, 1fr) auto; gap: 9px; margin-bottom: 18px; }
.filter-bar input, .filter-bar select, .record-form input, .record-form select, .record-form textarea, .status-form input, .status-form select { width: 100%; min-height: 45px; padding: 10px 12px; border: 1px solid #cfd9e3; border-radius: 7px; outline: none; color: var(--ink); background: #fff; }
.record-form input:focus, .record-form select:focus, .record-form textarea:focus, .filter-bar input:focus, .filter-bar select:focus { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(15,139,120,.10); }
.record-form label { display: grid; gap: 7px; color: #314158; font-size: 12px; font-weight: 700; }
.record-form label small { color: var(--muted); font-size: 10px; font-weight: 400; line-height: 1.5; }
.record-form textarea { resize: vertical; }
.form-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 17px; }
.field-wide { grid-column: 1 / -1; }
.form-actions, .button-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 20px; }
.form-actions .btn, .button-row .btn { display: inline-grid; place-items: center; }
.btn-danger { color: #fff; background: #b42335; }
.danger-zone { margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--line); }
.setup-note { margin-top: 25px; padding: 16px; border-radius: 9px; color: #415267; background: #f3f7fa; font-size: 12px; line-height: 1.65; }
.setup-note h3 { margin: 0 0 7px; }.setup-note p { margin: 0 0 7px; }
.manage-grid { display: grid; grid-template-columns: minmax(0,1fr) 340px; gap: 16px; align-items: start; }
.record-form { display: grid; gap: 15px; }
.record-form .check { display: flex; align-items: center; gap: 8px; }.record-form .check input { width: auto; min-height: 0; }
.data-table td:nth-child(2) { min-width: 250px; }
.status.draft, .status.filed { border: 1px solid #b8c6d5; color: #45566a; background: #eff3f7; }
.status.committee-review { border: 1px solid #a7b8ee; color: #3b4b93; background: #eef1ff; }
.detail-grid { display: grid; grid-template-columns: minmax(0,1fr) 340px; gap: 16px; align-items: start; }
.record-details { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 0; margin: 10px 0 0; border: 1px solid var(--line); border-radius: 9px; overflow: hidden; }
.record-details > div { padding: 13px 15px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.record-details dt { margin-bottom: 5px; color: var(--muted); font-size: 9px; font-weight: 800; text-transform: uppercase; }.record-details dd { margin: 0; font-size: 12px; line-height: 1.6; }
.status-form { display: grid; grid-template-columns: 190px minmax(0,1fr) auto; gap: 9px; margin-top: 18px; }
.timeline-card > form { margin-top: 18px; }.timeline { margin-top: 12px; }.timeline article { position: relative; display: grid; grid-template-columns: 16px 1fr; gap: 10px; padding-bottom: 18px; }.timeline article::before { position: absolute; top: 12px; bottom: 0; left: 5px; width: 2px; background: #dbe5e9; content: ''; }.timeline article:last-child::before { display:none; }.timeline i { position: relative; z-index:1; width: 12px; height: 12px; margin-top: 2px; border: 3px solid #bce8df; border-radius:50%; background:var(--teal); }.timeline strong { font-size:11px; }.timeline p { margin:4px 0; color:#526176; font-size:10px; line-height:1.5; }.timeline small { color:#8793a2; font-size:8px; }
.simple-list { margin: 10px 0 0; padding:0; list-style:none; }.simple-list li { display:flex; justify-content:space-between; padding:11px 0; border-bottom:1px solid var(--line); color:#526176; font-size:11px; }.simple-list b { color:var(--ink); }
.upload-progress { position: relative; height: 34px; overflow:hidden; border-radius:7px; background:#e8eef3; }.upload-progress span { position:absolute; inset:0 auto 0 0; width:0; background:linear-gradient(90deg,#14a38e,#087c70); transition:width .15s; }.upload-progress strong { position:relative; z-index:1; display:grid; height:100%; place-items:center; color:#fff; font-size:10px; text-shadow:0 1px 2px #0005; }
.setup-screen { min-height:100vh; }.setup-screen .login-panel-inner { max-width:580px; }

@media (max-width: 1280px) {
    .sidebar { width: 210px; }
    .dashboard-main { margin-left: 210px; }
    .stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .stat-card { padding: 16px; }
    .content-grid { grid-template-columns: minmax(0, 1fr) 260px; }
}

@media (max-width: 1024px) {
    .login-shell { grid-template-columns: 1fr 440px; }
    .hero-copy { width: calc(100% - 40px); padding-left: 34px; }
    .hero-copy h1 { font-size: 42px; }
    .monument-card { left: 34px; width: 190px; }
    .sidebar { transform: translateX(-100%); transition: transform .25s ease; }
    .sidebar-open .sidebar { transform: translateX(0); }
    .sidebar-backdrop { position: fixed; z-index: 25; inset: 0; display: block; pointer-events: none; opacity: 0; background: rgba(4, 25, 45, .48); transition: opacity .25s; }
    .sidebar-open .sidebar-backdrop { pointer-events: auto; opacity: 1; }
    .mobile-menu { position: fixed; z-index: 22; top: 17px; left: 17px; display: grid; width: 43px; height: 43px; padding: 10px; border: 0; border-radius: 8px; place-content: center; gap: 4px; background: var(--navy-deep); box-shadow: 0 4px 14px rgba(7,55,97,.25); }
    .mobile-menu span { display: block; width: 20px; height: 2px; border-radius: 2px; background: #fff; }
    .dashboard-main { margin-left: 0; padding-top: 75px; }
    .content-grid { grid-template-columns: 1fr; }
    .right-column { grid-template-columns: .8fr 1.2fr; }
    .manage-grid, .detail-grid { grid-template-columns: 1fr; }
}

@media (max-width: 800px) {
    .login-shell { display: block; }
    .login-hero { min-height: 460px; }
    .hero-copy { padding-top: 70px; }
    .hero-copy h1 { font-size: clamp(35px, 8vw, 50px); }
    .hero-copy p { max-width: 75%; font-size: 14px; }
    .monument-card { right: 25px; bottom: 28px; left: auto; width: 145px; }
    .monument-card figcaption { display: none; }
    .login-panel { padding-block: 48px; }
    .topbar { align-items: flex-start; }
    .topbar-actions { flex-wrap: wrap; justify-content: flex-end; }
    .global-search { order: 3; width: 100%; }
    .chart-grid { grid-template-columns: 1fr; }
    .filter-bar { grid-template-columns: 1fr 1fr; }.filter-bar input { grid-column:1/-1; }
}

@media (max-width: 640px) {
    .login-hero { min-height: 420px; }
    .hero-copy { width: calc(100% - 32px); padding: 48px 16px 0; }
    .hero-copy h1 { font-size: 34px; }
    .hero-copy p { max-width: 100%; font-size: 13px; }
    .monument-card { right: 16px; bottom: 16px; width: 112px; }
    .login-panel { padding: 36px 16px; }
    .login-brand strong { font-size: 24px; }
    .login-card { padding: 24px 18px; }
    .form-options { font-size: 11px; }
    .dashboard-main { padding-right: 12px; padding-left: 12px; }
    .topbar { display: block; }
    .topbar-actions { justify-content: flex-start; margin-top: 16px; }
    .global-search { width: 100%; }
    .user-chip div { display: none; }
    .stat-grid { grid-template-columns: 1fr; }
    .stat-card { min-height: 100px; }
    .right-column { grid-template-columns: 1fr; }
    .form-grid, .record-details, .status-form, .filter-bar { grid-template-columns: 1fr; }
    .field-wide { grid-column:auto; }.section-heading { display:block; }.section-heading .btn { margin-top:14px; display:inline-grid; }
    .panel-heading { align-items: flex-start; }
    .panel-heading > a { display: none; }
    .tabs { max-width: calc(100vw - 58px); overflow-x: auto; }
    .tabs button { white-space: nowrap; }
    .type-content { flex-direction: column; }
    .type-content ul { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
