/* GRC Evidence Assistant v2.2 visual system. Styles are deliberately scoped so
   the wp-admin shell and frontend WordPress themes cannot leak into the app. */
.grcai-wrap, .grcai-wrap *, .grcai-wrap *::before, .grcai-wrap *::after { box-sizing: border-box; }
.grcai-wrap {
  --grcai-navy: #dff2ff; --grcai-navy-2: #eef8ff; --grcai-blue: #3b82b8;
  --grcai-ink: #172033; --grcai-muted: #65738b; --grcai-line: #dfe6ef;
  --grcai-canvas: #f3f6fa; --grcai-card: #fff;
  width: auto; max-width: none; margin: 18px 20px 30px 0; color: var(--grcai-ink); background: var(--grcai-canvas);
  border: 1px solid #d7e0eb; border-radius: 16px; overflow: hidden;
  box-shadow: 0 12px 34px rgba(20,43,73,.09);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; line-height: 1.5;
}
.grcai-wrap p, .grcai-wrap li, .grcai-wrap label, .grcai-wrap span, .grcai-wrap div,
.grcai-wrap h1, .grcai-wrap h2, .grcai-wrap h3, .grcai-wrap h4, .grcai-wrap strong { color: inherit; }
.grcai-loading { padding: 48px 4px; color: var(--grcai-muted); }

/* Header */
.grcai-app-header {
  min-height: 92px; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 20px 26px; color: #17324d;
  background: linear-gradient(118deg, var(--grcai-navy), var(--grcai-navy-2)); border-bottom: 1px solid #c6e2f4;
}
.grcai-brand { display: flex; align-items: center; gap: 14px; }
.grcai-title { margin: 0 !important; padding: 0 !important; color: #17324d !important; font-size: 21px !important; font-weight: 720 !important; line-height: 1.2 !important; letter-spacing: -.02em; }
.grcai-brand p { margin: 4px 0 0; color: #5d7892; font-size: 12px; letter-spacing: .02em; }
.grcai-header-tools { display: flex; align-items: center; justify-content: flex-end; gap: 16px; }
.grcai-client-switcher { display: flex; align-items: center; gap: 9px; color: #42647f; font-size: 11px; font-weight: 700; }
.grcai-client-switcher select { min-width: 210px; height: 36px; padding: 4px 30px 4px 10px !important; background: rgba(255,255,255,.92) !important; border-color: #afd3e8 !important; }
.grcai-health { position: relative; max-width: 460px; text-align: right; }
.grcai-health-chip { display: inline-flex; align-items: center; gap: 8px; padding: 7px 11px; border: 1px solid #b8d9ea; border-radius: 999px; background: rgba(255,255,255,.7); color: #315d78; font-size: 12px; font-weight: 650; }
.grcai-health-chip > span { width: 8px; height: 8px; border-radius: 50%; background: #4ade80; box-shadow: 0 0 0 4px rgba(74,222,128,.14); }
.grcai-health-warn > span { background: #fbbf24; box-shadow: 0 0 0 4px rgba(251,191,36,.14); }
.grcai-health-detail { margin-top: 6px; color: #56748d; font-size: 11px; line-height: 1.35; }

/* Workspace navigation */
.grcai-workspace { display: grid; grid-template-columns: 220px minmax(0,1fr); min-height: 680px; }
.grcai-sidebar { padding: 20px 12px; background: #f9fcff; border-right: 1px solid #d6e9f5; }
.grcai-nav-label { padding: 0 12px 9px; color: #94a0b3; font-size: 10px; font-weight: 750; letter-spacing: .13em; text-transform: uppercase; }
.grcai-tabs { display: flex; flex-direction: column; gap: 3px; }
.grcai-tab { width: 100%; display: flex; align-items: center; gap: 11px; padding: 10px 12px; border: 0; border-radius: 9px; background: transparent; color: #526077; cursor: pointer; font: inherit; font-size: 13px; font-weight: 560; text-align: left; transition: background .16s,color .16s,transform .16s; }
.grcai-tab:hover { background: #f0f5fb; color: #1f4f7d; transform: translateX(2px); }
.grcai-tab.active { background: linear-gradient(100deg,#dcefff,#edf9ff); color: #245f86; font-weight: 700; box-shadow: inset 3px 0 #56a5d8; }
.grcai-panel { min-width: 0; padding: 26px 28px 38px; background: var(--grcai-canvas); overflow-x: auto; }

/* Dashboard */
.grcai-page-heading { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 22px; }
.grcai-page-heading h2 { margin: 2px 0 4px; font-size: 27px; line-height: 1.2; letter-spacing: -.035em; }
.grcai-page-heading p { margin: 0; color: var(--grcai-muted); font-size: 13px; }
.grcai-eyebrow { color: #2870c7 !important; font-size: 10px; font-weight: 800; letter-spacing: .14em; }
.grcai-coverage-ring { --coverage: 0; position: relative; width: 88px; height: 88px; display: grid; place-content: center; flex: none; border-radius: 50%; background: conic-gradient(#22a7c7 calc(var(--coverage) * 1%),#dfe8f1 0); }
.grcai-coverage-ring::before { content: ""; position: absolute; inset: 8px; border-radius: 50%; background: var(--grcai-canvas); }
.grcai-coverage-ring strong, .grcai-coverage-ring span { position: relative; z-index: 1; text-align: center; }
.grcai-coverage-ring strong { font-size: 19px; line-height: 1; }
.grcai-coverage-ring span { margin-top: 4px; color: var(--grcai-muted); font-size: 9px; text-transform: uppercase; letter-spacing: .08em; }
.grcai-cards { display: grid; grid-template-columns: repeat(5,minmax(135px,1fr)); gap: 12px; margin-bottom: 18px; }
.grcai-card { position: relative; min-height: 128px; padding: 16px; overflow: hidden; background: var(--grcai-card); border: 1px solid var(--grcai-line); border-radius: 12px; box-shadow: 0 4px 14px rgba(20,43,73,.045); }
.grcai-card::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: #c8d4e2; }
.grcai-card-primary::after { background: #2563eb; } .grcai-card-warning::after { background: #f59e0b; }
.grcai-card-danger::after { background: #ef4444; } .grcai-card-success::after { background: #22a06b; }
.grcai-card-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.grcai-card-title { color: #65738b; font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.grcai-card-big { margin: 12px 0 5px; color: #132238; font-size: 28px; font-weight: 750; line-height: 1; letter-spacing: -.04em; }
.grcai-card-sub { color: #7a8799; font-size: 11px; }
.grcai-dashboard-grid { display: grid; grid-template-columns: minmax(0,1.18fr) minmax(280px,.82fr); gap: 16px; margin-bottom: 18px; }
.grcai-dashboard-block { padding: 18px; background: #fff; border: 1px solid var(--grcai-line); border-radius: 12px; box-shadow: 0 4px 14px rgba(20,43,73,.04); }
.grcai-block-heading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.grcai-block-heading h3 { margin: 2px 0 0; font-size: 16px; }
.grcai-count-pill { padding: 4px 9px; border-radius: 999px; background: #eef3f8; color: #64748b; font-size: 10px; font-weight: 700; }
.grcai-action-list { display: flex; flex-direction: column; }
.grcai-action-row { display: grid; grid-template-columns: minmax(0,1fr) auto 16px; align-items: center; gap: 10px; width: 100%; padding: 11px 6px; border: 0; border-bottom: 1px solid #edf1f5; background: transparent; color: var(--grcai-ink); cursor: pointer; text-align: left; }
.grcai-action-row:last-child { border-bottom: 0; } .grcai-action-row:hover { background: #f7faff; }
.grcai-action-label { color: #3b485c; font-size: 12px; font-weight: 580; }
.grcai-action-row strong { min-width: 24px; padding: 2px 7px; border-radius: 999px; background: #edf1f5; color: #65738b; font-size: 11px; text-align: center; }
.grcai-action-row strong.has-items { background: #fff0e6; color: #bd4e19; }
.grcai-action-row > span:last-child { color: #8ba0b5; font-size: 18px; }
.grcai-stat-group { padding: 10px 0; border-bottom: 1px solid #edf1f5; }
.grcai-stat-group:last-child { border-bottom: 0; } .grcai-stat-group h4 { margin: 0 0 7px; color: #65738b; font-size: 11px; font-weight: 700; }
.grcai-chart-bars { display: flex; flex-direction: column; gap: 7px; }
.grcai-chart-row { display: grid; grid-template-columns: 78px minmax(80px,1fr) 24px; align-items: center; gap: 8px; font-size: 10px; }
.grcai-chart-row > span { color: #607286; text-transform: capitalize; }
.grcai-chart-row > div { height: 8px; overflow: hidden; border-radius: 999px; background: #edf2f6; }
.grcai-chart-row i { height: 100%; display: block; border-radius: 999px; background: #79b9df; }
.grcai-chart-row i.grcai-chart-low { background: #51b987; } .grcai-chart-row i.grcai-chart-medium { background: #e7bd55; }
.grcai-chart-row i.grcai-chart-high { background: #e68b58; } .grcai-chart-row i.grcai-chart-critical { background: #d85b61; }
.grcai-chart-row strong { color: #43566c; font-size: 10px; text-align: right; }
.grcai-ai-briefing { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: 18px; margin-bottom: 18px; padding: 18px; border: 1px solid #bedff2; border-radius: 12px; background: linear-gradient(110deg,#e8f7ff,#f5fbff); }
.grcai-ai-briefing h3 { margin: 2px 0 3px; color: #264f6c; font-size: 16px; }
.grcai-ai-briefing p { margin: 0; color: #647c8e; font-size: 11px; }
.grcai-ai-briefing #grcai-briefing-output { grid-column: 1 / -1; }
.grcai-briefing { padding-top: 15px; border-top: 1px solid #cfe5f2; }
.grcai-briefing > h4 { margin: 0 0 5px; color: #1e4664; font-size: 15px; }
.grcai-briefing > p { font-size: 12px; }
.grcai-priority-list { display: grid; grid-template-columns: repeat(auto-fit,minmax(220px,1fr)); gap: 9px; margin-top: 14px; }
.grcai-priority-list button { display: grid; grid-template-columns: 25px minmax(0,1fr); gap: 9px; padding: 12px; border: 1px solid #d4e6f1; border-radius: 9px; background: #fff; color: #233f55; cursor: pointer; text-align: left; }
.grcai-priority-list button:hover { border-color: #83bbdb; }
.grcai-priority-list button > span { width: 23px; height: 23px; display: grid; place-items: center; border-radius: 50%; background: #dff1fb; color: #38779f; font-size: 10px; font-weight: 800; }
.grcai-priority-list strong { display: block; font-size: 11px; } .grcai-priority-list p { margin: 3px 0 6px; font-size: 10px; }
.grcai-priority-list b { color: #3d6c89; font-size: 10px; font-weight: 700; }
.grcai-positive { margin-top: 12px !important; padding: 9px 11px; border-radius: 7px; background: #e8f8ef; color: #2f7050 !important; }

/* Client portfolio and AI assistant */
.grcai-intelligence-hero { position: relative; min-height: 154px; display: grid; grid-template-columns: 72px minmax(0,1fr) auto; align-items: center; gap: 20px; margin-bottom: 15px; padding: 26px 28px; overflow: hidden; border: 1px solid #afd9ef; border-radius: 16px; background: radial-gradient(circle at 75% 15%,rgba(255,255,255,.94),transparent 28%),linear-gradient(125deg,#dff4ff,#eff9ff 58%,#e4f5ff); box-shadow: 0 8px 24px rgba(46,115,158,.09); }
.grcai-intelligence-hero::after { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .28; background-image: radial-gradient(#6bb5df 1px,transparent 1px); background-size: 18px 18px; mask-image: linear-gradient(90deg,transparent 30%,#000); }
.grcai-intelligence-copy { position: relative; z-index: 1; }
.grcai-intelligence-copy h2 { margin: 6px 0 5px; color: #173f5a; font-size: 27px; line-height: 1.15; letter-spacing: -.035em; }
.grcai-intelligence-copy p { max-width: 760px; margin: 0; color: #526f83; font-size: 13px; }
.grcai-ai-presence { display: flex; align-items: center; gap: 7px; color: #2b7199 !important; font-size: 9px; font-weight: 850; letter-spacing: .14em; }
.grcai-ai-presence b, .grcai-live-label::before { width: 7px; height: 7px; display: inline-block; border-radius: 50%; background: #25a56f; box-shadow: 0 0 0 4px rgba(37,165,111,.12); }
.grcai-ai-orb { position: relative; z-index: 1; width: 64px; height: 64px; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.9); border-radius: 50%; background: radial-gradient(circle at 32% 28%,#fff 0 8%,#8bd8f5 25%,#4da9da 55%,#236f9e 100%); box-shadow: 0 0 0 8px rgba(92,181,226,.12),0 12px 28px rgba(28,104,148,.22); animation: grcai-orb-float 4s ease-in-out infinite; }
.grcai-ai-orb::before, .grcai-ai-orb::after, .grcai-ai-orb i { content: ""; position: absolute; border: 1px solid rgba(255,255,255,.72); border-radius: 50%; }
.grcai-ai-orb::before { width: 38px; height: 38px; transform: rotate(28deg) scaleY(.42); }
.grcai-ai-orb::after { width: 47px; height: 47px; transform: rotate(-34deg) scaleX(.38); }
.grcai-ai-orb i { width: 9px; height: 9px; background: rgba(255,255,255,.92); box-shadow: 0 0 12px #fff; }
.grcai-ai-orb.small { width: 42px; height: 42px; flex: none; box-shadow: 0 0 0 5px rgba(92,181,226,.1); }
.grcai-ai-orb.small::before { width: 25px; height: 25px; } .grcai-ai-orb.small::after { width: 31px; height: 31px; }
@keyframes grcai-orb-float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
.grcai-ai-pulse { position: relative; z-index: 1; display: flex; align-items: end; gap: 4px; height: 26px; padding: 0 5px; }
.grcai-ai-pulse span { width: 3px; height: 10px; border-radius: 4px; background: #5daed8; animation: grcai-listen .8s ease-in-out infinite alternate; }
.grcai-ai-pulse span:nth-child(2) { height: 22px; animation-delay: -.35s; } .grcai-ai-pulse span:nth-child(3) { height: 15px; animation-delay: -.6s; }
.grcai-ai-pulse.ready span { animation-duration: 1.8s; opacity: .62; }
@keyframes grcai-listen { to { height: 5px; opacity: .45; } }
.grcai-intelligence-loading { display: flex; align-items: center; gap: 10px; margin-bottom: 15px; padding: 15px 18px; border: 1px solid #d3e6f2; border-radius: 12px; background: #fff; color: #5f7588; font-size: 11px; }
.grcai-intelligence-loading b { width: 9px; height: 9px; border: 2px solid #b8dced; border-top-color: #358dbd; border-radius: 50%; animation: grcai-spin .8s linear infinite; }
@keyframes grcai-spin { to { transform: rotate(360deg); } }
.grcai-intelligence-grid { display: grid; grid-template-columns: minmax(0,1.35fr) minmax(270px,.65fr); gap: 14px; margin-bottom: 14px; }
.grcai-ai-brief, .grcai-ai-watch, .grcai-ai-queue { padding: 19px; border: 1px solid #d6e5ee; border-radius: 13px; background: #fff; box-shadow: 0 4px 15px rgba(28,73,103,.04); }
.grcai-live-label { display: inline-flex; align-items: center; gap: 6px; color: #50809d; font-size: 9px; font-weight: 800; letter-spacing: .08em; }
.grcai-live-label::before { content: ""; width: 6px; height: 6px; box-shadow: none; }
.grcai-ai-summary { min-height: 38px; margin: 2px 0 15px; color: #4d6374; font-size: 12px; line-height: 1.6; }
.grcai-ai-metrics { display: grid; grid-template-columns: repeat(3,1fr); gap: 8px; }
.grcai-ai-metrics > div { padding: 11px; border-radius: 9px; background: #f2f8fc; }
.grcai-ai-metrics strong { display: block; color: #245f83; font-size: 21px; line-height: 1; }
.grcai-ai-metrics span { display: block; margin-top: 5px; color: #718394; font-size: 9px; }
.grcai-ai-positive { display: flex; gap: 9px; margin-top: 10px; padding: 9px 11px; border-radius: 8px; background: #eefaf4; color: #38745a; font-size: 10px; }
.grcai-ai-positive b { flex: none; }
.grcai-watch-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid #edf2f5; }
.grcai-watch-row div strong, .grcai-watch-row div span { display: block; } .grcai-watch-row div strong { color: #3c5365; font-size: 11px; } .grcai-watch-row div span { margin-top: 2px; color: #8996a2; font-size: 9px; }
.grcai-watch-row > b { padding: 3px 7px; border-radius: 999px; background: #e8f8ef; color: #28714e; font-size: 9px; white-space: nowrap; }
.grcai-watch-row > b.needs-attention { background: #fff0e5; color: #ae5528; }
.grcai-watch-note { margin: 10px 0 0; color: #8897a5; font-size: 9px; }
.grcai-ai-queue { margin-bottom: 15px; }
.grcai-ai-priority-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(235px,1fr)); gap: 9px; }
.grcai-ai-priority { display: grid; grid-template-columns: 27px minmax(0,1fr); gap: 10px; padding: 13px; border: 1px solid #dce8ef; border-radius: 10px; background: linear-gradient(145deg,#fff,#f8fbfd); }
.grcai-priority-rank { color: #6a9cba; font-size: 10px; font-weight: 850; letter-spacing: .06em; }
.grcai-ai-priority strong { display: block; color: #2d4b60; font-size: 11px; }
.grcai-ai-priority p { margin: 3px 0 8px; color: #6e7f8d; font-size: 9px; line-height: 1.45; }
.grcai-ai-priority b { color: #60849a; font-size: 8px; letter-spacing: .08em; text-transform: uppercase; }
.grcai-ai-priority button { padding: 0; border: 0; background: none; color: #2879aa; cursor: pointer; font-size: 9px; font-weight: 800; }
.grcai-ai-priority button:hover { color: #145c88; text-decoration: underline; }
.grcai-ai-clear { grid-column: 1/-1; padding: 14px; border-radius: 9px; background: #f1faf5; color: #3f7059; }
.grcai-ai-clear p { margin: 3px 0 0; font-size: 10px; }
.grcai-command-deck { margin-bottom: 15px; padding: 20px; border: 1px solid #b8dced; border-radius: 14px; background: linear-gradient(125deg,#e9f8ff,#f8fcff); box-shadow: 0 6px 20px rgba(38,112,153,.07); }
.grcai-command-heading { display: flex; align-items: end; justify-content: space-between; gap: 15px; margin-bottom: 12px; }
.grcai-command-heading h3 { margin: 3px 0 0; color: #214b66; font-size: 18px; }
.grcai-command-heading > span { color: #6d899b; font-size: 9px; }
.grcai-command-form textarea { min-height: 104px !important; padding: 14px !important; border-color: #bcd9e9 !important; border-radius: 10px !important; background: rgba(255,255,255,.94) !important; font-size: 13px !important; line-height: 1.55; }
.grcai-command-footer { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-top: 10px; }
.grcai-command-footer .grcai-quick-prompts { margin: 0; }
.grcai-command-footer > .button { flex: none; min-height: 38px !important; }
.grcai-ai-working { display: flex; align-items: center; gap: 18px; margin-bottom: 15px; padding: 18px 20px; border: 1px solid #b9dff1; border-radius: 13px; background: linear-gradient(110deg,#e8f7ff,#f7fcff); }
.grcai-ai-working strong { color: #245675; font-size: 13px; } .grcai-ai-working p { margin: 2px 0 9px; color: #688093; font-size: 10px; }
.grcai-ai-working > div:last-child > div { display: flex; gap: 5px; }
.grcai-ai-working > div:last-child span { padding: 3px 7px; border-radius: 999px; background: #fff; color: #5483a0; font-size: 8px; font-weight: 750; animation: grcai-step 1.5s ease-in-out infinite; }
.grcai-ai-working > div:last-child span:nth-child(2) { animation-delay: .3s; } .grcai-ai-working > div:last-child span:nth-child(3) { animation-delay: .6s; }
@keyframes grcai-step { 0%,100% { opacity: .45; } 50% { opacity: 1; box-shadow: 0 0 0 2px rgba(73,157,204,.1); } }
.grcai-client-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(250px,1fr)); gap: 13px; }
.grcai-client-card { min-height: 142px; display: flex; flex-direction: column; gap: 11px; padding: 16px; border: 1px solid #d9e6ef; border-radius: 12px; background: #fff; color: var(--grcai-ink); cursor: pointer; text-align: left; box-shadow: 0 3px 12px rgba(31,78,112,.035); }
.grcai-client-card:hover { border-color: #9bc7e3; background: #fafdff; }
.grcai-client-card.active { border-color: #68acd7; box-shadow: 0 0 0 3px rgba(104,172,215,.14); }
.grcai-client-card-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.grcai-client-card-top strong { font-size: 14px; }
.grcai-client-card-top > span { padding: 3px 8px; border-radius: 999px; background: #e4f3fc; color: #38729a; font-size: 10px; font-weight: 700; }
.grcai-client-industry { color: #6d7e90; font-size: 11px; }
.grcai-client-frameworks { margin-top: auto; }
.grcai-client-frameworks em { color: #94a0ad; font-size: 11px; }
.grcai-operator-compose, .grcai-operator-plan { margin-bottom: 16px; padding: 18px; background: #fff; border: 1px solid #d9e6ef; border-radius: 12px; box-shadow: 0 4px 14px rgba(31,78,112,.04); }
.grcai-quick-prompts { display: flex; gap: 7px; margin: -8px 0 13px; overflow-x: auto; }
.grcai-quick-prompts button { flex: none; padding: 7px 10px; border: 1px solid #c9e1ef; border-radius: 999px; background: #f3faff; color: #3d708f; cursor: pointer; font-size: 10px; font-weight: 700; }
.grcai-quick-prompts button:hover { background: #e4f4fd; }
.grcai-operator-compose .grcai-form { max-width: none; padding: 0; }
.grcai-operator-note { margin: 12px 0 0; padding-top: 12px; border-top: 1px solid #edf2f6; color: #6d7e90; font-size: 11px; }
.grcai-operator-plan > p { color: #53667a; font-size: 12px; }
.grcai-plan-list { margin: 15px 0; padding: 0; list-style: none; counter-reset: plan; }
.grcai-plan-list li { counter-increment: plan; display: grid; grid-template-columns: 28px minmax(0,1fr); align-items: start; gap: 10px; padding: 12px 0; border-bottom: 1px solid #edf2f6; }
.grcai-plan-list li::before { content: counter(plan); width: 24px; height: 24px; display: grid; place-items: center; border-radius: 50%; background: #e4f3fc; color: #39769e; font-size: 10px; font-weight: 800; }
.grcai-plan-list li > strong { grid-column: 2; font-size: 12px; }
.grcai-plan-reason { grid-column: 2; margin: -4px 0 1px; color: #63798a; font-size: 10px; }
.grcai-plan-reason b { color: #3c6f8e; }
.grcai-friendly-fields, .grcai-draft-preview { grid-column: 2; margin: 0; }
.grcai-friendly-fields { display: grid; grid-template-columns: repeat(auto-fit,minmax(180px,1fr)); gap: 7px; }
.grcai-friendly-fields > div { padding: 8px 9px; border-radius: 7px; background: #f5f8fb; }
.grcai-friendly-fields dt { color: #758496; font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; }
.grcai-friendly-fields dd { margin: 3px 0 0; color: #394d61; font-size: 11px; white-space: pre-wrap; }
.grcai-draft-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.grcai-document-preview { max-height: 340px; padding: 20px; overflow: auto; border: 1px solid #dce5ed; border-radius: 8px; background: #fff; color: #293a4d; box-shadow: inset 0 0 0 5px #f7f9fb; font-family: Georgia,serif; font-size: 12px; line-height: 1.65; }
.grcai-document-preview h2, .grcai-document-preview h3 { margin: 14px 0 6px; font-family: Georgia,serif; }
.grcai-document-preview p, .grcai-policy-body p { margin: 5px 0; }
.grcai-doc-space { height: 8px; } .grcai-doc-bullet { padding-left: 12px; }
.grcai-approval-bar { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 13px; border-radius: 9px; background: #eef8ff; color: #486c86; font-size: 11px; }
.grcai-execution-results { margin-top: 14px; }
.grcai-execution-row { display: flex; justify-content: space-between; gap: 18px; padding: 9px 11px; border-left: 3px solid #31a26d; background: #f2fbf6; font-size: 11px; }
.grcai-execution-row.failed { border-color: #d45454; background: #fff4f4; }
.grcai-policy-document { margin: 11px 0 3px; border: 1px solid #e0e8ef; border-radius: 8px; background: #f9fbfd; }
.grcai-policy-document summary { padding: 8px 11px; color: #3e708f; cursor: pointer; font-size: 11px; font-weight: 700; }
.grcai-policy-paper { margin: 0 10px 10px; padding: 25px; border: 1px solid #e0e5eb; background: #fff; box-shadow: 0 4px 12px rgba(30,60,80,.05); }
.grcai-policy-paper h2 { margin: 0 0 5px; font-family: Georgia,serif; font-size: 21px; }
.grcai-policy-meta { margin: 0 0 20px; padding-bottom: 12px; border-bottom: 1px solid #e7ebef; color: #75808d; font-size: 10px; text-transform: capitalize; }
.grcai-policy-body { margin-bottom: 20px; color: #283746; font-family: Georgia,serif; font-size: 12px; line-height: 1.7; }

/* Shared content */
.grcai-muted { color: var(--grcai-muted) !important; } .grcai-small { font-size: 12px; }
.grcai-tab-intro { max-width: 76ch; margin: 0 0 18px; color: var(--grcai-muted); font-size: 13px; }
.grcai-section { margin: 16px 0; } .grcai-section h3 { margin: 0 0 8px; font-size: 13px; }
.grcai-guide { padding: 16px 19px; background: linear-gradient(110deg,#ecf5ff,#edfafa); border: 1px solid #cfe2f3; border-radius: 12px; color: #35445a; font-size: 12px; }
.grcai-guide h3 { margin: 0 0 8px; color: #194f83; font-size: 13px; }
.grcai-guide ol { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 5px 24px; margin: 0; padding-left: 20px; }
.grcai-alert { margin: 10px 0; padding: 11px 14px; border: 1px solid; border-radius: 9px; font-size: 12px; }
.grcai-alert-error { background: #fff0f0; border-color: #f2b5b5; color: #8f1d22; }
.grcai-alert-warn { background: #fff8e6; border-color: #eed38a; color: #775a0a; }
.grcai-alert-ok { background: #eaf9f1; border-color: #9bd5b5; color: #176039; }
.grcai-badge { display: inline-flex; align-items: center; padding: 3px 8px; border-radius: 999px; background: #e9eef4; color: #4c596d; font-size: 10px; font-weight: 750; line-height: 1.35; }
.grcai-badge-low { background: #dcf7e9; color: #176b41; } .grcai-badge-medium { background: #fff2cc; color: #795b00; }
.grcai-badge-high { background: #ffe4d6; color: #a23b13; } .grcai-badge-critical { background: #ffe0e0; color: #a01920; }

/* Forms, tables, and records */
.grcai-add { margin-bottom: 16px; padding: 0; overflow: hidden; background: #fff; border: 1px solid var(--grcai-line); border-radius: 11px; box-shadow: 0 3px 12px rgba(20,43,73,.035); }
.grcai-add summary { padding: 12px 15px; color: #245f9c; cursor: pointer; font-size: 12px; font-weight: 700; list-style-position: inside; }
.grcai-add[open] summary { border-bottom: 1px solid #e8edf3; background: #f8fbff; }
.grcai-form { max-width: 720px; margin: 0; padding: 15px; display: grid; gap: 12px; }
.grcai-row { display: flex; flex-direction: column; gap: 5px; color: #4b586b; font-size: 11px; font-weight: 650; }
.grcai-wrap input, .grcai-wrap textarea, .grcai-wrap select { width: 100%; min-height: 38px; padding: 8px 10px !important; background: #fff !important; color: #182235 !important; border: 1px solid #cbd5e1 !important; border-radius: 7px !important; box-shadow: none !important; font: inherit !important; }
.grcai-wrap textarea { min-height: 76px; resize: vertical; }
.grcai-wrap input:focus, .grcai-wrap textarea:focus, .grcai-wrap select:focus { border-color: #3b82f6 !important; box-shadow: 0 0 0 3px rgba(59,130,246,.13) !important; outline: none !important; }
.grcai-wrap input::placeholder, .grcai-wrap textarea::placeholder { color: #99a4b3 !important; opacity: 1; }
.grcai-wrap .button, .grcai-wrap .button-primary, .grcai-wrap button[type="submit"], .grcai-wrap button.button { width: auto; min-height: 34px; display: inline-flex; align-items: center; justify-content: center; padding: 6px 12px !important; border: 1px solid #c7d2df !important; border-radius: 7px !important; background: #fff !important; color: #314158 !important; box-shadow: 0 1px 2px rgba(20,43,73,.04) !important; cursor: pointer; font-size: 11px !important; font-weight: 650 !important; }
.grcai-wrap .button-primary, .grcai-wrap button[type="submit"] { border-color: #2563eb !important; background: linear-gradient(135deg,#2563eb,#1674c9) !important; color: #fff !important; }
.grcai-wrap .button:hover { border-color: #8fa4ba !important; background: #f7faff !important; }
.grcai-wrap .button-primary:hover, .grcai-wrap button[type="submit"]:hover { filter: brightness(.96); }
.grcai-wrap button:disabled { cursor: not-allowed; opacity: .58; }
.button-link-delete { border: 0; background: none; color: #c0393e; cursor: pointer; font-size: 11px; text-decoration: none; }
.button-link-delete:hover { text-decoration: underline; }
.button-link { padding: 0; border: 0; background: none; color: #2563eb; cursor: pointer; font: inherit; text-decoration: none; }
.grcai-table { width: 100%; margin-top: 8px; border-collapse: separate; border-spacing: 0; overflow: hidden; background: #fff; border: 1px solid var(--grcai-line); border-radius: 10px; }
.grcai-table th, .grcai-table td { padding: 10px 11px; color: inherit; border: 0; border-bottom: 1px solid #e8edf3; background: transparent; font-size: 12px; text-align: left; vertical-align: top; }
.grcai-table th { background: #f7f9fc; color: #5e6d82; font-size: 10px; font-weight: 750; letter-spacing: .035em; text-transform: uppercase; }
.grcai-table tr:last-child td { border-bottom: 0; } .grcai-table tbody tr:hover { background: #f9fbfe; }
.grcai-item, .grcai-evidence-item { margin-bottom: 11px; padding: 14px 16px; background: #fff; border: 1px solid var(--grcai-line); border-radius: 11px; box-shadow: 0 3px 12px rgba(20,43,73,.035); }
.grcai-item-head, .grcai-evidence-head { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.grcai-item-head > strong, .grcai-evidence-head > strong { color: #16243a; font-size: 13px; }
.grcai-item-actions { display: flex; gap: 7px; margin-top: 10px; flex-wrap: wrap; }
.grcai-mapping-ul { margin: 10px 0 0; padding-left: 20px; } .grcai-mapping-result { margin-top: 5px; }
.grcai-answer { margin-top: 10px; padding: 13px 15px; background: #f2f7fc; border-radius: 9px; }
.grcai-report-textarea { width: 100%; min-height: 420px; font: 12px/1.55 Consolas,Monaco,monospace !important; }
.grcai-busy { display: inline-flex; align-items: center; gap: 7px; margin-left: 8px; color: var(--grcai-muted); font-size: 11px; }
.grcai-spinner { width: 13px; height: 13px; flex: none; border: 2px solid #ccd5df; border-top-color: #2563eb; border-radius: 50%; animation: grcai-spin .7s linear infinite; }
@keyframes grcai-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .grcai-tab { transition: none; } .grcai-spinner { animation-duration: 2.2s; } }

/* Frontend shortcode shell */
.grcai-frontend { margin: 20px 0; }
.grcai-frontend-gate { max-width: 420px; margin: 30px auto; padding: 22px; border: 1px solid #dfe6ef; border-radius: 12px; background: #fff; color: #172033; text-align: center; box-shadow: 0 10px 30px rgba(20,43,73,.08); }
.grcai-frontend-gate * { box-sizing: border-box; } .grcai-frontend-gate form p { text-align: left; }

@media (max-width: 1180px) { .grcai-cards { grid-template-columns: repeat(3,minmax(150px,1fr)); } }
@media (max-width: 900px) {
  .grcai-wrap { margin-right: 10px; } .grcai-workspace { display: block; }
  .grcai-sidebar { padding: 9px 12px; border-right: 0; border-bottom: 1px solid var(--grcai-line); overflow-x: auto; }
  .grcai-nav-label { display: none; } .grcai-tabs { min-width: max-content; flex-direction: row; }
  .grcai-tab { width: auto; padding: 8px 10px; } .grcai-tab:hover { transform: none; }
  .grcai-tab.active { box-shadow: inset 0 -3px #2563eb; } .grcai-dashboard-grid, .grcai-intelligence-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .grcai-wrap { margin: 10px 5px 20px 0; border-radius: 11px; } .grcai-app-header { align-items: flex-start; padding: 17px; flex-direction: column; }
  .grcai-header-tools { width: 100%; align-items: flex-start; flex-direction: column; } .grcai-client-switcher { width: 100%; align-items: flex-start; flex-direction: column; }
  .grcai-client-switcher select { width: 100%; } .grcai-health { text-align: left; } .grcai-panel { padding: 20px 14px 30px; } .grcai-page-heading { align-items: flex-start; }
  .grcai-coverage-ring { width: 72px; height: 72px; } .grcai-cards { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .grcai-card { min-height: 120px; padding: 13px; } .grcai-guide ol { grid-template-columns: 1fr; }
  .grcai-table { display: block; overflow-x: auto; white-space: nowrap; }
  .grcai-ai-briefing { grid-template-columns: 1fr; } .grcai-ai-briefing #grcai-briefing-output { grid-column: 1; }
  .grcai-plan-list li { grid-template-columns: 28px minmax(0,1fr); } .grcai-approval-bar { align-items: stretch; flex-direction: column; }
  .grcai-policy-paper { padding: 16px; }
  .grcai-intelligence-hero { grid-template-columns: 48px minmax(0,1fr); padding: 20px 16px; } .grcai-ai-orb { width: 44px; height: 44px; }
  .grcai-ai-orb::before { width: 27px; height: 27px; } .grcai-ai-orb::after { width: 33px; height: 33px; } .grcai-ai-pulse { display: none; }
  .grcai-intelligence-copy h2 { font-size: 21px; } .grcai-ai-metrics { grid-template-columns: 1fr; }
  .grcai-command-heading, .grcai-command-footer { align-items: stretch; flex-direction: column; } .grcai-command-footer > .button { width: 100% !important; }
}
@media (prefers-reduced-motion: reduce) { .grcai-ai-orb, .grcai-ai-pulse span, .grcai-intelligence-loading b, .grcai-ai-working span { animation: none !important; } }

/* FHT integrated build: deliberate, motion-free enterprise UI. */
.grcai-wrap *, .grcai-wrap *::before, .grcai-wrap *::after { animation: none !important; transition: none !important; }
.grcai-intelligence-hero::after, .grcai-ai-orb, .grcai-ai-pulse { display: none !important; }
