/* Recurring GL Setup (Story 5677, 2026-11-02) -- the web twin of the desktop's
   GL Recurring Transaction Setup. A pinned header and tab bar over one scroller
   that holds only the chosen tab's cards. */

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body { background: #F2F2F4; color: #222; font-family: "Segoe UI", system-ui, sans-serif; }

.gr-shell.page-shell { display: flex; flex-direction: column; height: 100vh; height: 100dvh; overflow: hidden; }
.gr-shell #lwIconBand, .gr-shell .ct-header, .gr-shell .gr-tabs { flex: 0 0 auto; }

/* .ct-header is only the icon band's marker, so it gets its look here. */
.ct-header { background: #3C3C3C; color: #fff; padding: 10px 16px; display: flex; align-items: center; gap: 10px; }
.ct-header h1 { margin: 0; font-size: 14pt; font-weight: 600; flex: 1; min-width: 0; }
.ct-header button { color: #fff; background: #0A66C2; border: none; border-radius: 4px; padding: 7px 14px; font: inherit; font-size: 13px; cursor: pointer; white-space: nowrap; }
.ct-header button:hover { background: #084E96; }

/* ---- tab bar ---- */
.gr-tabs { display: flex; align-items: center; background: #fff; border-bottom: 2px solid #DDDDE0; overflow-x: auto; -webkit-overflow-scrolling: touch; }
.gr-tab { padding: 10px 14px; font: inherit; font-size: 13px; font-weight: 500; color: #555; background: none; border: none; border-bottom: 2px solid transparent; margin-bottom: -2px; cursor: pointer; white-space: nowrap; }
.gr-tab.active { color: #0A66C2; border-bottom-color: #0A66C2; font-weight: 600; }
.gr-tab-count { font-size: 11px; color: #888; font-weight: 500; }
.gr-tab-spacer { flex: 1; }
.gr-foldall { background: none; border: 1px solid #D3D3D9; border-radius: 4px; color: #555; font: inherit; font-size: 11px; padding: 3px 8px; margin-right: 10px; cursor: pointer; }
.gr-foldall[hidden] { display: none; }

/* ---- the one scroller ---- */
.gr-body { flex: 1; overflow: auto; padding: 12px 14px 28px; }
.gr-status { font-size: 12px; color: #666; margin-bottom: 10px; min-height: 14px; }
.gr-list { display: flex; flex-direction: column; gap: 8px; }
.gr-more { margin: 14px auto 0; display: block; border: 1px solid #D3D3D9; background: #fff; border-radius: 6px; padding: 8px 18px; font: inherit; font-size: 13px; cursor: pointer; }
.gr-more[hidden] { display: none; }

/* ---- a card: a head line that folds the rest away ---- */
.gr-card { background: #fff; border: 1px solid #E2E2E6; border-left: 4px solid #0A66C2; border-radius: 8px; box-shadow: 0 1px 3px rgba(0,0,0,.05); }
.gr-card.is-closed { border-left-color: #15803D; }
.gr-card.is-closed .gr-title { color: #4B5563; font-weight: 500; }
.gr-head { display: flex; align-items: center; gap: 8px; padding: 10px 12px; cursor: pointer; user-select: none; }
.gr-caret { color: #888; font-size: 11px; width: 12px; flex: 0 0 auto; }
.gr-title { flex: 1; min-width: 0; font-size: 14px; font-weight: 600; color: #1B1B1F; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gr-done { color: #15803D; font-weight: 700; }
.gr-amount { font-size: 14px; font-weight: 600; color: #1B1B1F; white-space: nowrap; }
.gr-detail { padding: 0 12px 10px 32px; font-size: 12px; color: #555; }
.gr-card.collapsed .gr-detail { display: none; }
.gr-line { margin: 2px 0; }
.gr-line b { color: #333; font-weight: 600; }
.gr-next { display: inline-block; font-size: 11px; font-weight: 600; border-radius: 999px; padding: 2px 9px; background: #E5F0FF; color: #1F4E8C; }
.gr-next.is-done { background: #DCFCE7; color: #15803D; }
.gr-notes { margin-top: 4px; color: #666; white-space: pre-wrap; overflow-wrap: anywhere; }
.gr-actions { display: flex; gap: 14px; margin-top: 8px; }
.gr-actions a { font-size: 12px; font-weight: 600; color: #0A66C2; text-decoration: none; cursor: pointer; }
.gr-actions a.danger { color: #B42318; }

/* ---- History: the postings table inside the sepia sheet ---- */
.gr-hist { width: 100%; border-collapse: collapse; font-size: 13px; white-space: normal; }
.gr-hist th { text-align: left; font-size: 11px; font-weight: 600; color: #6b5d40; text-transform: uppercase; letter-spacing: .03em; padding: 4px 6px; border-bottom: 1px solid #d8c9a6; }
.gr-hist td { padding: 5px 6px; border-bottom: 1px dotted #e3d6b8; vertical-align: top; }
.gr-hist tr:last-child td { border-bottom: 0; }
.gr-hist .num { text-align: right; white-space: nowrap; }
.gr-hist .date { white-space: nowrap; }
.gr-hist .rec { text-align: center; white-space: nowrap; }
.gr-hist td.rec { color: #15803D; font-weight: 700; }
.gr-hist tfoot td { border-top: 1px solid #d8c9a6; border-bottom: 0; font-weight: 600; }
.gr-hist-empty { color: #9c8c6a; }
@media (max-width: 520px) { .gr-hist { font-size: 12px; } .gr-hist th, .gr-hist td { padding: 4px 3px; } }
