:root {
  --bg: #050816;
  --surface: rgba(11, 19, 41, 0.82);
  --surface-strong: rgba(14, 24, 50, 0.92);
  --text: #f5f8ff;
  --muted: #98a5cf;
  --line: rgba(159, 181, 255, 0.14);
  --brand: #53a7ff;
  --brand-deep: #8d67ff;
  --gold: #54e6ff;
  --green: #50d5b7;
  --shadow: 0 30px 90px rgba(0, 0, 0, 0.32);
  --radius-xl: 28px;
  --radius-lg: 22px;
  --radius-md: 14px;
}

/* MeshLine OS — modern workflow workspace */ #dashboardScreen { --os-cyan: #55dcff; --os-blue: #5a8cff; --os-violet: #a56cff; --os-green: #58e6b2; --os-ink: #07101f; } #dashboardScreen .workspace-shell { grid-template-columns: 224px minmax(0, 1fr); gap: 0; overflow: hidden; border: 1px solid rgba(142, 168, 228, 0.16); border-radius: 22px; background: rgba(5, 10, 23, 0.96); box-shadow: 0 32px 100px rgba(0, 0, 0, 0.42); } #dashboardScreen .workspace-sidebar { border: 0; border-right: 1px solid rgba(142, 168, 228, 0.12); border-radius: 0; background: radial-gradient(circle at 24% 0%, rgba(85, 220, 255, 0.08), transparent 24%), rgba(6, 12, 27, 0.98); } #dashboardScreen .workspace-main { gap: 14px; padding: 0 18px 28px; background: radial-gradient(circle at 70% 0%, rgba(90, 140, 255, 0.075), transparent 24%), linear-gradient(180deg, rgba(8, 15, 33, 0.98), rgba(5, 10, 23, 0.98)); } #dashboardScreen .workspace-header { top: 0; min-height: 70px; margin-inline: -18px; padding: 10px 18px; border: 0; border-bottom: 1px solid rgba(142, 168, 228, 0.12); border-radius: 0; background: rgba(7, 13, 29, 0.88); box-shadow: none; backdrop-filter: blur(22px); } #dashboardScreen .workspace-utility-strip { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; min-height: 54px; } #dashboardScreen .workspace-utility-pill { min-height: 42px; padding: 6px 9px; } #dashboardScreen .workspace-route-chip { border-color: rgba(142, 168, 228, 0.14); color: rgba(226, 235, 255, 0.74); background: rgba(255, 255, 255, 0.035); } #dashboardScreen .workspace-nav-button { min-height: 54px; border: 1px solid transparent; border-radius: 14px; } #dashboardScreen .workspace-nav-button:hover, #dashboardScreen .workspace-nav-button.active { border-color: rgba(85, 220, 255, 0.16); background: linear-gradient(110deg, rgba(85, 220, 255, 0.1), rgba(90, 140, 255, 0.055)); box-shadow: inset 3px 0 0 var(--os-cyan); } #dashboardScreen .workspace-panel { border-color: rgba(142, 168, 228, 0.13); background: rgba(10, 18, 38, 0.76); box-shadow: 0 22px 54px rgba(0, 0, 0, 0.18); } .mesh-os-home { position: relative; display: grid; gap: 18px; padding: clamp(20px, 2.4vw, 34px) !important; overflow: hidden; background: radial-gradient(circle at 76% 10%, rgba(90, 140, 255, 0.16), transparent 34%), radial-gradient(circle at 94% 48%, rgba(165, 108, 255, 0.1), transparent 28%), linear-gradient(150deg, rgba(12, 24, 50, 0.96), rgba(7, 14, 31, 0.98)) !important; } .mesh-os-home::after { position: absolute; inset: 0; pointer-events: none; content: ""; background-image: linear-gradient(rgba(126, 155, 221, 0.025) 1px, transparent 1px), linear-gradient(90deg, rgba(126, 155, 221, 0.025) 1px, transparent 1px); background-size: 38px 38px; mask-image: linear-gradient(90deg, transparent, #000 46%, #000); } .mesh-os-home > * { position: relative; z-index: 1; } .mesh-os-hero-grid { display: grid; grid-template-columns: minmax(0, 0.92fr) minmax(420px, 1.08fr); gap: clamp(24px, 4vw, 64px); align-items: center; } .mesh-os-hero-copy { display: grid; gap: 14px; } .mesh-os-kicker-row, .mesh-os-primary-actions, .mesh-os-live-head, .mesh-os-live-title-group, .mesh-os-live-progress-row, .mesh-os-flow-caption, .workspace-project-card-state, .workspace-project-progress-head, .workspace-project-connection-row { display: flex; align-items: center; } .mesh-os-kicker-row { gap: 9px; } .mesh-os-kicker, .mesh-os-environment, .mesh-os-time-badge { display: inline-flex; gap: 7px; align-items: center; width: max-content; padding: 6px 9px; border: 1px solid rgba(142, 168, 228, 0.16); border-radius: 999px; color: rgba(220, 232, 255, 0.7); background: rgba(255, 255, 255, 0.035); font-size: 0.66rem; font-weight: 850; letter-spacing: 0.04em; } .mesh-os-kicker { color: #ecfaff; } .mesh-os-kicker i { width: 7px; height: 7px; border-radius: 50%; background: var(--os-green); box-shadow: 0 0 14px rgba(88, 230, 178, 0.72); } .mesh-os-hero-copy h2 { max-width: 760px; margin: 0; color: #f7f9ff; font-size: clamp(2.1rem, 3.4vw, 4.2rem); line-height: 0.98; letter-spacing: -0.052em; text-wrap: balance; } .mesh-os-hero-copy > .helper-text { max-width: 690px; margin: 0; color: rgba(204, 217, 246, 0.72); font-size: clamp(0.94rem, 1.15vw, 1.08rem); line-height: 1.58; } .mesh-os-primary-actions { flex-wrap: wrap; gap: 9px; margin-top: 3px; } .mesh-os-primary-actions button { min-height: 44px; border-radius: 13px; } .mesh-os-create-button { gap: 8px; box-shadow: 0 14px 30px rgba(75, 145, 255, 0.22); } .mesh-os-create-button span { display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 7px; color: #07101f; background: #fff; font-size: 1rem; } .mesh-os-flow-visual { position: relative; min-height: 314px; overflow: hidden; border: 1px solid rgba(109, 169, 255, 0.2); border-radius: 26px; background: radial-gradient(circle at 50% 50%, rgba(90, 140, 255, 0.13), transparent 30%), rgba(3, 9, 23, 0.68); box-shadow: inset 0 0 50px rgba(85, 220, 255, 0.025), 0 26px 70px rgba(0, 0, 0, 0.24); } .mesh-os-flow-grid { position: absolute; inset: 0; opacity: 0.48; background-image: linear-gradient(rgba(116, 151, 223, 0.08) 1px, transparent 1px), linear-gradient(90deg, rgba(116, 151, 223, 0.08) 1px, transparent 1px); background-size: 32px 32px; mask-image: radial-gradient(circle, #000, transparent 78%); } .mesh-os-flow-node, .mesh-os-flow-core { position: absolute; z-index: 3; display: flex; gap: 10px; align-items: center; border: 1px solid rgba(124, 169, 245, 0.22); background: rgba(9, 20, 43, 0.94); box-shadow: 0 18px 40px rgba(0, 0, 0, 0.26), inset 0 0 24px rgba(85, 220, 255, 0.035); } .mesh-os-flow-node { top: 50%; width: 174px; min-height: 64px; padding: 10px 13px; border-radius: 18px; transform: translateY(-50%); } .mesh-os-flow-node--source { left: 5%; } .mesh-os-flow-node--outcome { right: 5%; } .mesh-os-flow-node small, .mesh-os-flow-core small { display: block; color: rgba(190, 207, 240, 0.58); font-size: 0.6rem; } .mesh-os-flow-node strong, .mesh-os-flow-core strong { display: block; margin-top: 2px; color: #f4f8ff; font-size: 0.76rem; } .mesh-os-flow-icon { display: inline-grid; flex: 0 0 auto; place-items: center; width: 34px; height: 34px; border-radius: 11px; color: #07101f; background: linear-gradient(135deg, var(--os-cyan), #82f0ff); font-size: 0.74rem; font-weight: 950; } .mesh-os-flow-node--outcome .mesh-os-flow-icon { background: linear-gradient(135deg, var(--os-green), #a2ffd6); } .mesh-os-flow-core { inset: 50% auto auto 50%; display: grid; place-items: center; width: 136px; height: 136px; gap: 2px; border-radius: 36px; transform: translate(-50%, -50%); } .mesh-os-flow-core img { width: 54px; height: 54px; border-radius: 15px; animation: mesh-os-float 4s ease-in-out infinite; } .mesh-os-core-orbit { position: absolute; inset: -24px; border: 1px solid rgba(85, 220, 255, 0.16); border-radius: 50%; animation: mesh-os-spin 14s linear infinite; } .mesh-os-core-orbit::after { position: absolute; top: 12%; right: 8%; width: 8px; height: 8px; border-radius: 50%; content: ""; background: var(--os-cyan); box-shadow: 0 0 18px rgba(85, 220, 255, 0.8); } .mesh-os-flow-line { position: absolute; z-index: 2; top: 50%; width: calc(50% - 205px); height: 2px; overflow: hidden; background: linear-gradient(90deg, rgba(85, 220, 255, 0.08), rgba(85, 220, 255, 0.62), rgba(165, 108, 255, 0.08)); } .mesh-os-flow-line--one { left: calc(5% + 174px); } .mesh-os-flow-line--two { right: calc(5% + 174px); } .mesh-os-flow-line i { position: absolute; top: -2px; width: 24px; height: 6px; border-radius: 99px; background: #aaf4ff; filter: blur(1px); box-shadow: 0 0 12px rgba(85, 220, 255, 0.9); animation: mesh-os-flow 2.2s linear infinite; } .mesh-os-flow-caption { position: absolute; inset: auto 22px 18px; justify-content: center; gap: 18px; color: rgba(190, 207, 240, 0.54); font-size: 0.62rem; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase; } .mesh-os-flow-caption span { display: flex; gap: 6px; align-items: center; } .mesh-os-flow-caption i { width: 5px; height: 5px; border-radius: 50%; background: var(--os-cyan); } .mesh-os-live-deck { display: grid; gap: 10px; padding: 15px 17px; border: 1px solid rgba(124, 169, 245, 0.16); border-radius: 19px; background: rgba(3, 9, 23, 0.56); } .mesh-os-live-deck[data-live-state="running"] { border-color: rgba(88, 230, 178, 0.24); box-shadow: inset 0 0 28px rgba(88, 230, 178, 0.035); } .mesh-os-live-head { justify-content: space-between; gap: 14px; } .mesh-os-live-title-group { gap: 10px; } .mesh-os-live-title-group small { display: block; color: rgba(192, 210, 244, 0.58); font-size: 0.64rem; font-weight: 850; letter-spacing: 0.08em; text-transform: uppercase; } .mesh-os-live-title-group strong { display: block; margin-top: 3px; color: #f3f7ff; font-size: 0.9rem; } .mesh-os-live-pulse { position: relative; width: 12px; height: 12px; border: 2px solid rgba(88, 230, 178, 0.36); border-radius: 50%; background: var(--os-green); box-shadow: 0 0 14px rgba(88, 230, 178, 0.5); } [data-live-state="running"] .mesh-os-live-pulse::after { position: absolute; inset: -7px; border: 1px solid rgba(88, 230, 178, 0.42); border-radius: 50%; content: ""; animation: mesh-os-pulse 1.8s ease-out infinite; } .mesh-os-live-progress-row { gap: 12px; } .mesh-os-live-progress-track { flex: 1; height: 8px; overflow: hidden; border-radius: 99px; background: rgba(122, 151, 210, 0.12); } .mesh-os-live-progress-track span { position: relative; display: block; height: 100%; min-width: 8px; overflow: hidden; border-radius: inherit; background: linear-gradient(90deg, var(--os-cyan), var(--os-blue), var(--os-violet)); box-shadow: 0 0 18px rgba(85, 220, 255, 0.34); transition: width 600ms cubic-bezier(.2,.8,.2,1); } [data-live-state="running"] .mesh-os-live-progress-track span::after { position: absolute; inset: 0; content: ""; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.64), transparent); transform: translateX(-100%); animation: mesh-os-shimmer 1.8s ease-in-out infinite; } .mesh-os-live-progress-row > strong { min-width: 44px; color: #e8f7ff; font-size: 0.78rem; text-align: right; } .mesh-os-live-deck > p { margin: 0; color: rgba(195, 211, 242, 0.66); font-size: 0.76rem; } .mesh-os-live-stages { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; } .mesh-os-live-stages span { padding: 7px 9px; border: 1px solid rgba(126, 154, 215, 0.11); border-radius: 9px; color: rgba(181, 201, 237, 0.46); background: rgba(255, 255, 255, 0.025); font-size: 0.64rem; font-weight: 800; text-align: center; } .mesh-os-live-stages span.done, .mesh-os-live-stages span.active { border-color: rgba(85, 220, 255, 0.22); color: #eafaff; background: rgba(85, 220, 255, 0.08); } .mesh-os-live-stages span.active { box-shadow: inset 0 -2px 0 var(--os-cyan), 0 0 18px rgba(85, 220, 255, 0.08); } .mesh-os-home-support-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; } .mesh-os-home-support-grid > section { min-width: 0; border-color: rgba(142, 168, 228, 0.12); background: rgba(255, 255, 255, 0.025); } .mesh-os-signal-strip { grid-template-columns: repeat(3, minmax(0, 1fr)); } .mesh-os-signal-strip .workspace-home-action-card { min-height: 96px; padding: 13px; border-color: rgba(142, 168, 228, 0.11); border-radius: 14px; background: rgba(255, 255, 255, 0.025); } .mesh-os-launchpad { padding: clamp(20px, 2.1vw, 28px) !important; } .mesh-os-launchpad .workspace-panel-head { align-items: flex-end; } .mesh-os-time-badge { color: #c8fff0; border-color: rgba(88, 230, 178, 0.2); background: rgba(88, 230, 178, 0.06); } .mesh-os-launchpad-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 18px; } .mesh-os-launch-card { position: relative; display: grid; gap: 10px; min-height: 224px; padding: 18px; overflow: hidden; border: 1px solid rgba(142, 168, 228, 0.13); border-radius: 18px; color: inherit; text-align: left; background: radial-gradient(circle at 90% 0%, rgba(85, 220, 255, 0.07), transparent 30%), rgba(5, 12, 28, 0.66); transition: transform 240ms ease, border-color 240ms ease, background 240ms ease, box-shadow 240ms ease; } .mesh-os-launch-card:hover, .mesh-os-launch-card:focus-visible { border-color: rgba(85, 220, 255, 0.3); background: rgba(9, 20, 43, 0.88); box-shadow: 0 18px 38px rgba(0, 0, 0, 0.22), inset 0 0 26px rgba(85, 220, 255, 0.035); transform: translateY(-4px); } .mesh-os-launch-number { color: var(--os-cyan); font-size: 0.65rem; font-weight: 900; letter-spacing: 0.1em; } .mesh-os-launch-card > strong { color: #f5f8ff; font-size: 1rem; } .mesh-os-launch-card > p { margin: 0; color: rgba(195, 211, 242, 0.66); font-size: 0.78rem; line-height: 1.5; } .mesh-os-launch-action { display: flex; gap: 8px; align-items: center; align-self: end; color: #dff9ff; font-size: 0.73rem; font-weight: 850; } .mesh-os-launch-action b { color: var(--os-cyan); font-size: 1rem; transition: transform 200ms ease; } .mesh-os-launch-card:hover .mesh-os-launch-action b { transform: translateX(4px); } .mesh-os-launch-graphic { display: flex; gap: 8px; align-items: center; min-height: 42px; } .mesh-os-launch-graphic i { display: inline-grid; place-items: center; width: 34px; height: 34px; border: 1px solid rgba(85, 220, 255, 0.22); border-radius: 11px; color: #dffaff; background: rgba(85, 220, 255, 0.07); font-size: 0.68rem; font-style: normal; font-weight: 900; } .mesh-os-launch-graphic--workflow i { width: 38px; height: 8px; border: 0; border-radius: 99px; background: linear-gradient(90deg, var(--os-cyan), var(--os-blue)); box-shadow: 0 0 12px rgba(85, 220, 255, 0.14); } .mesh-os-launch-graphic--workflow i:nth-child(2) { width: 62px; } .mesh-os-launch-graphic--workflow i:nth-child(3) { width: 26px; background: var(--os-green); } .mesh-os-launch-graphic--website { position: relative; width: 94px; padding: 7px; border: 1px solid rgba(85, 220, 255, 0.18); border-radius: 11px; background: rgba(85, 220, 255, 0.045); } .mesh-os-launch-graphic--website i { width: 7px; height: 7px; border: 0; background: var(--os-cyan); } .mesh-os-launch-graphic--website::after { flex: 1; height: 4px; border-radius: 99px; content: ""; background: rgba(171, 200, 243, 0.18); } #dashboardScreen .workspace-project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; } #dashboardScreen .workspace-project-card { display: grid; gap: 15px; min-height: 350px; padding: 19px; border-color: rgba(142, 168, 228, 0.13); border-radius: 20px; background: radial-gradient(circle at 90% 0%, rgba(90, 140, 255, 0.1), transparent 32%), linear-gradient(150deg, rgba(12, 22, 46, 0.95), rgba(7, 14, 31, 0.96)); box-shadow: 0 20px 46px rgba(0, 0, 0, 0.18); } #dashboardScreen .workspace-project-card:hover, #dashboardScreen .workspace-project-card:focus-visible, #dashboardScreen .workspace-project-card.active { border-color: rgba(85, 220, 255, 0.3); box-shadow: 0 24px 54px rgba(0, 0, 0, 0.24), inset 0 0 36px rgba(85, 220, 255, 0.035); transform: translateY(-3px); } .workspace-project-card-state { gap: 7px; color: rgba(201, 216, 244, 0.64); font-size: 0.68rem; font-weight: 800; } .workspace-project-status-dot { width: 7px; height: 7px; border-radius: 50%; background: rgba(167, 189, 231, 0.4); } .workspace-project-status-dot.is-live { background: var(--os-green); box-shadow: 0 0 12px rgba(88, 230, 178, 0.7); animation: mesh-os-pulse-dot 1.7s ease-in-out infinite; } #dashboardScreen .workspace-project-avatar { width: 52px; height: 52px; border-radius: 16px; background: linear-gradient(145deg, rgba(85, 220, 255, 0.12), rgba(165, 108, 255, 0.1)); } #dashboardScreen .workspace-project-copy small { display: block; margin-bottom: 3px; color: var(--os-cyan); font-size: 0.62rem; font-weight: 900; letter-spacing: 0.08em; text-transform: uppercase; } #dashboardScreen .workspace-project-copy > strong { font-size: 1.08rem; } .workspace-project-flow { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; } .workspace-project-flow span { position: relative; display: grid; justify-items: center; gap: 5px; color: rgba(179, 199, 235, 0.44); font-size: 0.58rem; font-weight: 800; text-align: center; } .workspace-project-flow span:not(:last-child)::after { position: absolute; top: 11px; left: calc(50% + 13px); width: calc(100% - 26px); height: 1px; content: ""; background: rgba(131, 165, 226, 0.16); } .workspace-project-flow i { position: relative; z-index: 1; display: inline-grid; place-items: center; width: 23px; height: 23px; border: 1px solid rgba(131, 165, 226, 0.17); border-radius: 8px; color: rgba(196, 216, 248, 0.52); background: #0b1630; font-size: 0.57rem; font-style: normal; } .workspace-project-flow span.is-ready { color: rgba(224, 240, 255, 0.78); } .workspace-project-flow span.is-ready i { border-color: rgba(85, 220, 255, 0.28); color: #dffaff; background: rgba(85, 220, 255, 0.09); } .workspace-project-progress-head { justify-content: space-between; gap: 10px; color: rgba(193, 210, 241, 0.62); font-size: 0.65rem; } .workspace-project-progress-head span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .workspace-project-progress-head strong { color: #eaf7ff; } #dashboardScreen .workspace-project-progress { height: 7px; overflow: visible; background: rgba(122, 151, 210, 0.1); } #dashboardScreen .workspace-project-progress > span { position: relative; background: linear-gradient(90deg, var(--os-cyan), var(--os-blue), var(--os-violet)); box-shadow: 0 0 15px rgba(85, 220, 255, 0.24); } #dashboardScreen .workspace-project-progress i { position: absolute; top: 50%; right: -4px; width: 9px; height: 9px; border: 2px solid #dffaff; border-radius: 50%; background: var(--os-cyan); box-shadow: 0 0 12px rgba(85, 220, 255, 0.65); transform: translateY(-50%); } .workspace-project-connection-row { flex-wrap: wrap; gap: 7px; } .workspace-project-connection-row span { padding: 6px 8px; border: 1px solid rgba(243, 183, 93, 0.15); border-radius: 8px; color: rgba(245, 203, 139, 0.72); background: rgba(243, 183, 93, 0.055); font-size: 0.61rem; font-weight: 800; } .workspace-project-connection-row span.is-connected { border-color: rgba(88, 230, 178, 0.18); color: rgba(174, 255, 222, 0.8); background: rgba(88, 230, 178, 0.055); } #dashboardScreen .workspace-project-stats { border-top: 1px solid rgba(142, 168, 228, 0.1); padding-top: 12px; } @keyframes mesh-os-flow { from { transform: translateX(-30px); } to { transform: translateX(430px); } } @keyframes mesh-os-spin { to { transform: rotate(360deg); } } @keyframes mesh-os-float { 50% { transform: translateY(-5px); } } @keyframes mesh-os-shimmer { to { transform: translateX(100%); } } @keyframes mesh-os-pulse { from { opacity: 0.8; transform: scale(0.6); } to { opacity: 0; transform: scale(1.4); } } @keyframes mesh-os-pulse-dot { 50% { opacity: 0.58; box-shadow: 0 0 4px rgba(88, 230, 178, 0.3); } } @media (prefers-reduced-motion: reduce) { .mesh-os-flow-line i, .mesh-os-core-orbit, .mesh-os-flow-core img, .mesh-os-live-pulse::after, .mesh-os-live-progress-track span::after, .workspace-project-status-dot.is-live { animation: none !important; } } @media (max-width: 1180px) { .mesh-os-hero-grid { grid-template-columns: 1fr; } .mesh-os-flow-visual { min-height: 286px; } } @media (max-width: 960px) { #dashboardScreen .workspace-shell { grid-template-columns: 1fr; } #dashboardScreen .workspace-main { padding-inline: 12px; } #dashboardScreen .workspace-header { margin-inline: -12px; padding-inline: 12px; } .mesh-os-launchpad-grid, #dashboardScreen .workspace-project-grid { grid-template-columns: 1fr; } .mesh-os-home-support-grid { grid-template-columns: 1fr; } } @media (max-width: 640px) { .mesh-os-home { padding: 18px 14px !important; } .mesh-os-hero-copy h2 { font-size: clamp(2rem, 10.5vw, 3rem); display: block !important; max-height: none !important; overflow: visible !important; text-overflow: clip !important; white-space: normal !important; -webkit-line-clamp: unset !important; } .mesh-os-environment { display: none; } .mesh-os-primary-actions { display: grid; grid-template-columns: 1fr; } .mesh-os-primary-actions button { width: 100%; } .mesh-os-signal-strip { grid-template-columns: 1fr; } .mesh-os-flow-visual { min-height: 390px; } .mesh-os-flow-node { left: 50%; right: auto; width: min(210px, calc(100% - 44px)); transform: translateX(-50%); } .mesh-os-flow-node--source { top: 42px; } .mesh-os-flow-node--outcome { top: auto; bottom: 54px; } .mesh-os-flow-core { width: 112px; height: 112px; border-radius: 30px; } .mesh-os-flow-line { left: 50%; width: 2px; height: 70px; transform: translateX(-50%); } .mesh-os-flow-line--one { top: 106px; } .mesh-os-flow-line--two { top: auto; right: auto; bottom: 118px; } .mesh-os-flow-line i { display: none; } .mesh-os-flow-caption { bottom: 14px; gap: 8px; } .mesh-os-live-head { align-items: flex-start; } .mesh-os-live-head button { padding-inline: 9px; font-size: 0.68rem; } .mesh-os-live-stages { grid-template-columns: repeat(2, minmax(0, 1fr)); } .mesh-os-launchpad { padding: 18px 14px !important; } .mesh-os-time-badge { display: none; } .workspace-project-flow span { font-size: 0; } }

* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: "Instrument Sans", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(83, 167, 255, 0.14), transparent 22%),
    radial-gradient(circle at top right, rgba(141, 103, 255, 0.18), transparent 24%),
    radial-gradient(circle at bottom center, rgba(84, 230, 255, 0.1), transparent 18%),
    linear-gradient(180deg, #040711 0%, #07101f 42%, #091426 100%);
}

body.app-booting {
  overflow: hidden;
}

body.viewport-locked {
  overflow: hidden;
}

button, input, textarea, select { font: inherit; }
button { cursor: pointer; border: 0; }

.app-language-switch {
  position: fixed;
  right: max(12px, env(safe-area-inset-right));
  bottom: calc(86px + env(safe-area-inset-bottom));
  z-index: 90;
  display: flex;
  gap: 4px;
  padding: 4px;
  border: 1px solid rgba(159, 181, 255, 0.22);
  border-radius: 999px;
  background: rgba(7, 12, 28, 0.86);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(14px);
}

.app-language-switch button {
  width: 42px;
  min-height: 34px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  background: transparent;
}

.app-language-switch button.active {
  color: #ffffff;
  background: linear-gradient(135deg, var(--brand), var(--brand-deep));
}

.app-language-modal {
  position: fixed;
  inset: 0;
  z-index: 180;
  display: grid;
  place-items: center;
  padding: 22px;
  background: rgba(3, 7, 18, 0.72);
  backdrop-filter: blur(18px);
}

.app-language-modal__panel {
  width: min(420px, 100%);
  padding: 24px;
  border: 1px solid rgba(159, 181, 255, 0.2);
  border-radius: 24px;
  background:
    radial-gradient(circle at top left, rgba(83, 167, 255, 0.14), transparent 34%),
    rgba(11, 19, 41, 0.96);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.42);
}

.app-language-modal__eyebrow {
  display: inline-flex;
  margin-bottom: 10px;
  color: var(--gold);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.app-language-modal__panel h2 {
  margin: 0;
  font-size: clamp(1.55rem, 6vw, 2rem);
  line-height: 1.05;
}

.app-language-modal__panel p {
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.55;
}

.app-language-modal__actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 20px;
}

.app-language-modal__actions button {
  min-height: 48px;
  border-radius: 14px;
  color: #ffffff;
  font-weight: 900;
  background: linear-gradient(135deg, var(--brand), var(--brand-deep));
}

@media (min-width: 820px) {
  .app-language-switch {
    bottom: 18px;
  }
}

.app-shell {
  width: min(1600px, calc(100% - 20px));
  margin: 0 auto;
  padding: 24px 0 48px;
}

.screen { display: none; }
.screen.active { display: block; }
#dashboardScreen.active,
#agentScreen.active,
#automationScreen.active,
#reportsScreen.active,
#platformAdminScreen.active {
  height: calc(100vh - 24px);
}
#loginScreen.active {
  display: grid;
  align-items: center;
  min-height: calc(100vh - 72px);
}

.app-boot-splash {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at 50% 38%, rgba(83, 167, 255, 0.16), transparent 22%),
    radial-gradient(circle at 50% 62%, rgba(84, 230, 255, 0.1), transparent 18%),
    linear-gradient(180deg, rgba(4, 8, 22, 0.88), rgba(5, 9, 20, 0.94));
  backdrop-filter: blur(18px);
  opacity: 1;
  visibility: visible;
  pointer-events: none;
  transition: opacity 320ms ease, visibility 320ms ease;
}

body.app-booting .app-boot-splash:not(.is-hidden) {
  pointer-events: auto;
}

body:not(.app-booting) .app-boot-splash {
  opacity: 0;
  visibility: hidden;
  pointer-events: none !important;
}

.app-boot-splash.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.app-boot-splash[hidden] {
  display: none !important;
}

.app-boot-splash__halo {
  position: absolute;
  width: min(54vw, 520px);
  aspect-ratio: 1;
  border-radius: 999px;
  background:
    radial-gradient(circle, rgba(174, 201, 255, 0.18) 0%, rgba(171, 181, 210, 0.12) 34%, rgba(126, 156, 214, 0.07) 58%, transparent 74%);
  filter: blur(10px);
  opacity: 0.82;
  animation: bootHaloDrift 4.6s ease-in-out infinite;
}

.app-boot-splash__card {
  position: relative;
  z-index: 1;
  width: min(500px, calc(100vw - 32px));
  padding: 30px 28px 24px;
  border-radius: 30px;
  text-align: center;
  background:
    radial-gradient(circle at top center, rgba(228, 235, 255, 0.08), transparent 32%),
    linear-gradient(180deg, rgba(28, 36, 63, 0.78), rgba(10, 16, 33, 0.62));
  border: 1px solid rgba(197, 210, 238, 0.18);
  box-shadow:
    0 24px 70px rgba(0, 0, 0, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    inset 0 -12px 22px rgba(19, 25, 46, 0.26);
  backdrop-filter: blur(20px);
}

.app-boot-splash__mark {
  width: 90px;
  height: 90px;
  margin: 0 auto 16px;
  padding: 11px;
  border-radius: 26px;
  background:
    linear-gradient(145deg, rgba(176, 191, 224, 0.18), rgba(97, 122, 176, 0.16), rgba(223, 230, 248, 0.08));
  border: 1px solid rgba(201, 211, 234, 0.18);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.04) inset,
    0 16px 38px rgba(42, 58, 108, 0.22),
    inset 0 -10px 18px rgba(28, 35, 66, 0.2);
  animation: bootMarkFloat 3s ease-in-out infinite;
}

.app-boot-splash__mark img {
  display: block;
  width: 100%;
  height: 100%;
}

.app-boot-splash__eyebrow {
  margin: 0 0 8px;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(115, 217, 255, 0.86);
}

.app-boot-splash__title {
  margin: 0;
  font-size: clamp(1.22rem, 2.8vw, 1.45rem);
  line-height: 1.1;
  white-space: nowrap;
  letter-spacing: -0.03em;
  color: rgba(246, 249, 255, 0.96);
  text-shadow: 0 10px 22px rgba(0, 0, 0, 0.18);
}

.app-boot-splash__text {
  margin: 10px auto 0;
  max-width: 280px;
  color: rgba(214, 223, 243, 0.72);
  line-height: 1.45;
  font-size: 0.96rem;
  text-transform: lowercase;
}

.app-boot-splash__pulse {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 18px;
}

.app-boot-splash__pulse span {
  width: 34px;
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(138, 168, 222, 0.28), rgba(224, 229, 240, 0.92), rgba(129, 148, 196, 0.34));
  box-shadow: 0 0 18px rgba(189, 199, 224, 0.16);
  animation: bootPulse 1.45s ease-in-out infinite;
  opacity: 0.42;
}

.app-boot-splash__pulse span:nth-child(2) {
  animation-delay: 160ms;
}

.app-boot-splash__pulse span:nth-child(3) {
  animation-delay: 320ms;
}

.login-layout, .hero-badges, .topbar, .brand-lockup, .topbar-actions, .dashboard-hero, .summary-row, .main-grid, .panel-head, .toolbar, .prompt-form, .builder-tabs {
  display: flex;
}

.main-grid, .app-grid, .card-grid, .builder-grid, .content, .webhook-studio, .agent-grid, .agent-column, .content-list, .agent-form, .agent-draft {
  display: grid;
  gap: 24px;
}

.topbar, .panel-head, .summary-row, .toolbar, .prompt-form {
  justify-content: space-between;
  align-items: center;
}

.login-layout {
  min-height: auto;
  align-items: center;
  justify-content: center;
  gap: 24px;
}

.auth-stack {
  display: grid;
  gap: 16px;
  width: min(392px, 100%);
}

.hero-card, .login-card, .sidebar-card, .view-panel, .builder-panel, .info-card, .input-card, .toggle-card, .summary-panel, .app-tile {
  background: var(--surface);
  border: 1px solid rgba(159, 181, 255, 0.12);
  backdrop-filter: blur(22px);
  box-shadow: var(--shadow);
  border-radius: var(--radius-xl);
}

.hero-card, .login-card, .sidebar-card, .view-panel, .builder-panel, .summary-panel {
  padding: 24px;
}

.hero-card {
  flex: 1;
  min-width: 320px;
}

.login-card {
  width: 100%;
  display: grid;
  gap: 16px;
}

.field, .input-card {
  display: grid;
  gap: 8px;
}

.field span, .input-card span, .input-inline span {
  color: var(--muted);
}

.eyebrow {
  margin: 0 0 6px;
  font-size: 0.76rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
}

h1, h2, h3, h4 {
  margin: 0;
  font-family: "Space Grotesk", sans-serif;
  color: var(--text);
}

.hero-text, .helper-text, .feed-list, .stack-list, .checklist, .app-tile p {
  color: var(--muted);
  line-height: 1.6;
}

.hero-badges, .topbar-actions, .builder-tabs {
  gap: 12px;
}

.pill {
  display: inline-flex;
  align-items: center;
  padding: 10px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(159, 181, 255, 0.14);
}

.pill.live {
  background: rgba(80, 213, 183, 0.12);
  color: #8df1d6;
}

.pill.release-pill {
  background: rgba(241, 196, 85, 0.12);
  color: #f3d98a;
  border-color: rgba(241, 196, 85, 0.22);
}

.topbar {
  margin-bottom: 28px;
}

.workspace-shell {
  display: grid;
  grid-template-columns: 234px minmax(0, 1fr);
  gap: 18px;
  min-height: calc(100vh - 72px);
}

.workspace-sidebar,
.workspace-main,
.workspace-brand-card,
.workspace-nav,
.workspace-sidebar-section,
.workspace-header,
.workspace-project-grid,
.workspace-home-grid,
.workspace-home-main,
.workspace-home-side,
.workspace-panel,
.workspace-panel-head,
.workspace-panel-actions,
.workspace-header-actions,
.workspace-route-chip,
.workspace-search-shell,
.workspace-nav-button,
.workspace-pinned-list,
.workspace-metric-grid,
.workspace-detail-grid,
.workspace-mini-panel,
.workspace-list,
.workspace-focus-copy,
.workspace-project-card,
.workspace-project-header,
.workspace-project-meta,
.workspace-project-stats,
.workspace-project-stat,
.workspace-project-footer,
.workspace-list-item,
.workspace-list-item-head {
  display: grid;
}

.workspace-sidebar,
.workspace-main,
.workspace-nav,
.workspace-sidebar-section,
.workspace-home-main,
.workspace-home-side,
.workspace-panel,
.workspace-pinned-list,
.workspace-list,
.workspace-focus-copy {
  gap: 18px;
}

.workspace-sidebar {
  align-content: start;
  position: sticky;
  top: 18px;
}

body.workspace-sidebar-collapsed .workspace-shell {
  grid-template-columns: 88px minmax(0, 1fr);
}

body.workspace-sidebar-collapsed .workspace-brand-card {
  grid-template-columns: 1fr;
  justify-items: center;
  padding-top: 16px;
}

body.workspace-sidebar-collapsed .workspace-brand-copy,
body.workspace-sidebar-collapsed .workspace-sidebar-section {
  display: none;
}

body.workspace-sidebar-collapsed .workspace-nav-button {
  grid-template-columns: 1fr;
  justify-items: center;
  padding: 14px 10px;
}

body.workspace-sidebar-collapsed .workspace-nav-copy {
  display: none;
}

.workspace-brand-card,
.workspace-sidebar-section,
.workspace-panel,
.workspace-nav-button,
.workspace-project-card,
.workspace-mini-panel,
.workspace-list-item {
  border: 1px solid rgba(159, 181, 255, 0.12);
  background: rgba(10, 18, 39, 0.88);
  backdrop-filter: blur(22px);
  box-shadow: var(--shadow);
}

.workspace-brand-card,
.workspace-sidebar-section,
.workspace-panel {
  border-radius: 28px;
  padding: 18px;
}

.workspace-brand-card {
  grid-template-columns: 60px minmax(0, 1fr) 40px;
  gap: 14px;
  align-items: center;
  background:
    radial-gradient(circle at top left, rgba(123, 101, 255, 0.18), transparent 34%),
    linear-gradient(180deg, rgba(15, 21, 46, 0.98), rgba(9, 14, 31, 0.96));
}

.workspace-brand-mark {
  width: 60px;
  height: 60px;
  border-radius: 20px;
  overflow: hidden;
  background: linear-gradient(135deg, var(--brand), var(--brand-deep) 55%, var(--gold));
  box-shadow: 0 16px 32px rgba(83, 167, 255, 0.24);
}

.workspace-brand-mark img {
  width: 100%;
  height: 100%;
  display: block;
}

.workspace-brand-copy {
  display: grid;
  gap: 4px;
}

.workspace-brand-line {
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
}

.workspace-brand-copy h2 {
  font-size: 1.56rem;
  line-height: 1;
}

.workspace-brand-tagline {
  color: rgba(205, 228, 255, 0.88);
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.workspace-brand-copy small {
  color: rgba(159, 176, 214, 0.82);
  font-size: 0.84rem;
}

.workspace-sidebar-toggle {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  border: 1px solid rgba(188, 202, 255, 0.22);
  background:
    linear-gradient(180deg, rgba(50, 56, 106, 0.94), rgba(28, 34, 69, 0.96));
  color: #f5f8ff;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.05) inset,
    0 12px 26px rgba(24, 26, 58, 0.28);
}

.workspace-sidebar-toggle span {
  grid-area: 1 / 1;
  width: 9px;
  height: 16px;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(255,255,255,0.96), rgba(160, 218, 255, 0.6));
}

.workspace-sidebar-toggle span:first-child {
  transform: translateX(-5px);
}

.workspace-sidebar-toggle span:last-child {
  transform: translateX(5px);
}

.workspace-nav-button {
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 12px;
  width: 100%;
  padding: 13px 14px;
  border-radius: 20px;
  text-align: left;
  color: var(--text);
  background:
    linear-gradient(180deg, rgba(24, 31, 61, 0.92), rgba(16, 22, 47, 0.96));
}

.workspace-nav-button.active {
  border-color: rgba(191, 214, 255, 0.34);
  background:
    radial-gradient(circle at left center, rgba(164, 117, 255, 0.2), transparent 34%),
    linear-gradient(135deg, rgba(84, 102, 194, 0.94), rgba(38, 48, 98, 0.98));
  box-shadow:
    0 0 0 1px rgba(228, 237, 255, 0.12) inset,
    0 18px 40px rgba(39, 41, 81, 0.24);
}

.workspace-nav-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(83, 167, 255, 0.34), rgba(141, 103, 255, 0.34));
  color: #fff;
  border: 1px solid rgba(202, 221, 255, 0.16);
  box-shadow: 0 10px 24px rgba(54, 72, 141, 0.18);
}

.workspace-nav-icon svg {
  width: 18px;
  height: 18px;
}

.workspace-nav-copy {
  display: grid;
  gap: 2px;
  align-content: center;
}

.workspace-nav-copy small {
  color: rgba(152, 165, 207, 0.78);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.62rem;
}

.workspace-nav-copy strong {
  font-size: 1.02rem;
}

.workspace-main {
  gap: 20px;
}

.workspace-header {
  grid-template-columns: max-content minmax(220px, 1fr) max-content;
  gap: 14px;
  align-items: center;
}

.workspace-route-chip {
  min-height: 54px;
  align-items: center;
  padding: 0 16px;
  border-radius: 20px;
  border: 1px solid rgba(159, 181, 255, 0.12);
  background: rgba(14, 21, 45, 0.9);
  font: 600 1rem "Space Grotesk", sans-serif;
}

.workspace-search-shell {
  grid-template-columns: max-content minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  min-height: 54px;
  padding: 0 16px;
  border-radius: 20px;
  border: 1px solid rgba(159, 181, 255, 0.12);
  background: rgba(14, 21, 45, 0.9);
}

.workspace-search-shell span {
  color: rgba(152, 165, 207, 0.78);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.62rem;
}

.workspace-search-shell input {
  width: 100%;
  border: 0;
  outline: none;
  background: transparent;
  color: var(--text);
}

.workspace-header-actions {
  grid-auto-flow: column;
  gap: 12px;
  align-items: center;
}

.workspace-panel {
  gap: 18px;
  background:
    radial-gradient(circle at bottom center, rgba(84, 230, 255, 0.08), transparent 26%),
    radial-gradient(circle at top right, rgba(173, 114, 255, 0.12), transparent 28%),
    linear-gradient(180deg, rgba(24, 30, 61, 0.96), rgba(11, 16, 35, 0.98));
}

.workspace-panel-head {
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 16px;
  align-items: start;
}

.workspace-project-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.workspace-project-card {
  gap: 14px;
  padding: 16px;
  border-radius: 24px;
  text-align: left;
  background:
    radial-gradient(circle at top left, rgba(114, 197, 255, 0.14), transparent 34%),
    linear-gradient(180deg, rgba(36, 49, 93, 0.98), rgba(26, 35, 70, 0.96));
}

.workspace-project-card.active {
  border-color: rgba(144, 208, 255, 0.34);
  background:
    radial-gradient(circle at top left, rgba(83, 167, 255, 0.22), transparent 38%),
    radial-gradient(circle at bottom right, rgba(205, 111, 255, 0.16), transparent 36%),
    linear-gradient(180deg, rgba(45, 69, 119, 0.98), rgba(28, 43, 85, 0.96));
}

.workspace-project-header,
.workspace-project-meta,
.workspace-project-footer,
.workspace-list-item-head {
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 12px;
  align-items: start;
}

.workspace-project-header strong {
  font-size: 0.98rem;
  font-family: "Space Grotesk", sans-serif;
  color: #f6f8ff;
}

.workspace-project-header p,
.workspace-project-footer span,
.workspace-project-description {
  margin: 0;
  color: rgba(216, 225, 248, 0.84);
}

.workspace-project-description {
  line-height: 1.5;
  font-size: 0.9rem;
}

.workspace-project-meta {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.workspace-project-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(159, 181, 255, 0.12);
  font-size: 0.82rem;
  color: #dfe8ff;
}

.workspace-project-stats,
.workspace-metric-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.workspace-project-stat,
.workspace-metric-card {
  padding: 12px;
  border-radius: 18px;
  border: 1px solid rgba(196, 214, 255, 0.12);
  background: rgba(255, 255, 255, 0.08);
  gap: 6px;
}

.workspace-project-stat span,
.workspace-metric-card span {
  color: rgba(152, 165, 207, 0.88);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.68rem;
}

.workspace-project-stat strong,
.workspace-metric-card strong {
  font: 700 1.16rem "Space Grotesk", sans-serif;
  color: #ffffff;
}

.workspace-project-stat small,
.workspace-metric-card small {
  color: var(--muted);
}

.workspace-home-grid {
  grid-template-columns: minmax(0, 1.5fr) minmax(330px, 0.68fr);
  gap: 16px;
}

.workspace-detail-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.workspace-mini-panel {
  gap: 12px;
  padding: 16px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.035);
}

.workspace-list-item {
  gap: 10px;
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.035);
}

.workspace-list-item span,
.workspace-list-item small {
  color: var(--muted);
}

.workspace-list-item strong {
  font-size: 1rem;
}

.workspace-list-item .pill {
  justify-self: start;
  padding: 8px 10px;
}

.workspace-focus-copy strong {
  font: 700 1.08rem "Space Grotesk", sans-serif;
}

.workspace-pinned-app {
  width: 100%;
  text-align: left;
  padding: 12px 14px;
  border-radius: 20px;
  border: 1px solid rgba(159, 181, 255, 0.12);
  background: linear-gradient(135deg, rgba(75, 92, 182, 0.34), rgba(89, 75, 180, 0.26));
  color: var(--text);
  display: grid;
  gap: 6px;
}

.workspace-pinned-app small {
  color: rgba(233, 239, 255, 0.7);
}

.workspace-pinned-app strong {
  font-size: 0.96rem;
}

.workspace-pinned-app span {
  color: #dce9ff;
  font-size: 0.85rem;
}

.workspace-shell-inner .agent-grid {
  grid-template-columns: minmax(260px, 320px) minmax(0, 1fr);
  gap: 16px;
}

.workspace-shell-inner .content-list {
  max-height: none;
}

.workspace-shell-inner .content-item,
.workspace-shell-inner .module-overview-shell,
.workspace-shell-inner .module-kpi-card,
.workspace-shell-inner .module-panel,
.workspace-shell-inner .info-card {
  border-radius: 20px;
}

.workspace-shell-inner .content-item {
  padding: 12px 14px;
  gap: 8px;
}

.workspace-shell-inner .module-overview-shell {
  padding: 18px;
  gap: 14px;
}

.workspace-shell-inner .module-kpi-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.workspace-shell-inner .module-kpi-card {
  padding: 12px 14px;
}

.workspace-shell-inner .module-kpi-card strong {
  font-size: 1.2rem;
}

.workspace-shell-inner .card-grid {
  gap: 16px;
}

.brand-lockup {
  align-items: center;
  gap: 14px;
}

.brand-mark, .tile-icon {
  width: 54px;
  height: 54px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--brand), var(--brand-deep) 55%, var(--gold));
  box-shadow: 0 16px 30px rgba(83, 167, 255, 0.28);
}

.brand-mark {
  overflow: hidden;
}

.brand-mark img {
  display: block;
  width: 100%;
  height: 100%;
}

.tile-icon {
  color: #fff;
  font: 700 1.4rem "Space Grotesk", sans-serif;
}

.dashboard-hero {
  justify-content: space-between;
  align-items: start;
  gap: 24px;
  margin-bottom: 28px;
}

.dashboard-hero-copy {
  display: grid;
  gap: 16px;
  max-width: 760px;
}

.summary-panel, .summary-list, .form-grid, .feed-list, .stack-list, .console-log {
  display: grid;
  gap: 12px;
}

.summary-row {
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  gap: 14px;
}

.summary-row:last-child {
  border-bottom: 0;
}

.app-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.app-tile {
  padding: 22px;
  text-align: left;
  display: grid;
  gap: 16px;
}

.app-tile strong {
  color: var(--text);
  display: block;
  margin-bottom: 6px;
}

.app-tile p {
  margin: 0;
}

.primary-tile {
  background:
    linear-gradient(135deg, rgba(83, 167, 255, 0.14), rgba(141, 103, 255, 0.18)),
    var(--surface);
}

.feature-tile {
  grid-column: 1 / -1;
  grid-template-columns: auto 1fr auto;
  align-items: center;
}

.tile-paths {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: end;
}

.main-grid {
  grid-template-columns: 320px 1fr;
  align-items: start;
}

.sidebar {
  display: grid;
  gap: 22px;
  position: sticky;
  top: 18px;
}

.sidebar-card {
  display: grid;
  gap: 12px;
}

.compact-stack {
  gap: 10px;
}

.nav-button {
  width: 100%;
  text-align: left;
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  border: 1px solid rgba(159, 181, 255, 0.1);
}

.nav-button.active, .builder-tab.active {
  background: linear-gradient(135deg, rgba(83, 167, 255, 0.14), rgba(141, 103, 255, 0.2));
  border: 1px solid rgba(83, 167, 255, 0.24);
}

.content {
  gap: 24px;
}

.webhook-overview-grid {
  grid-template-columns: 1fr;
}

.webhook-overview-grid .info-card {
  grid-column: 1 / -1;
  width: 100%;
}

.logs-section {
  align-items: start;
}

.full-width {
  grid-column: 1 / -1;
}

.connector-path-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.compact-create-card {
  margin-bottom: 18px;
}

.compact-webhook-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  align-items: start;
}

.compact-webhook-form .input-card {
  padding: 14px;
}

.compact-webhook-actions {
  grid-column: 1 / -1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.compact-summary-list .summary-row {
  padding: 10px 0;
}

.system-item {
  background: linear-gradient(135deg, rgba(83, 167, 255, 0.12), rgba(141, 103, 255, 0.14));
  border-color: rgba(83, 167, 255, 0.18);
}

.webhook-studio {
  grid-template-columns: 1.05fr 0.95fr 1fr;
  margin-bottom: 24px;
}

.agent-grid {
  grid-template-columns: minmax(320px, 420px) minmax(0, 1fr);
  align-items: start;
}

.marketing-agent-grid .agent-column:last-child {
  gap: 18px;
}

.panel-head.compact {
  margin-bottom: 12px;
}

.panel-head.compact .hero-badges {
  padding-bottom: 8px;
}

.module-overview-shell {
  display: grid;
  gap: 18px;
  margin-bottom: 20px;
  padding: 22px;
  border-radius: 24px;
  border: 1px solid rgba(159, 181, 255, 0.12);
  background:
    radial-gradient(circle at top right, rgba(141, 103, 255, 0.18), transparent 30%),
    radial-gradient(circle at bottom left, rgba(83, 167, 255, 0.12), transparent 24%),
    linear-gradient(180deg, rgba(13, 20, 44, 0.92), rgba(9, 15, 34, 0.96));
  box-shadow:
    0 24px 54px rgba(0, 0, 0, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.module-overview-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(260px, 0.75fr);
  gap: 18px;
  align-items: stretch;
}

.module-overview-copy,
.module-overview-status {
  display: grid;
  gap: 10px;
}

.module-overview-copy h4,
.module-panel h4 {
  font-size: 1.16rem;
}

.module-overview-status {
  padding: 18px;
  border-radius: 22px;
  border: 1px solid rgba(159, 181, 255, 0.14);
  background: rgba(255, 255, 255, 0.035);
  align-content: start;
}

.module-overview-status strong {
  font: 700 1.08rem "Space Grotesk", sans-serif;
}

.module-overview-status span:last-child {
  color: var(--muted);
  line-height: 1.55;
}

.module-kpi-grid,
.module-analytics-grid {
  display: grid;
  gap: 16px;
}

.module-kpi-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.module-kpi-card,
.module-panel,
.module-funnel-stage,
.module-trend-row,
.module-signal-card,
.module-rule-card {
  border-radius: 20px;
  border: 1px solid rgba(159, 181, 255, 0.12);
  background: rgba(255, 255, 255, 0.035);
}

.module-kpi-card {
  padding: 16px 18px;
  display: grid;
  gap: 8px;
}

.module-kpi-card span {
  color: var(--muted);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.module-kpi-card strong {
  font: 700 1.42rem "Space Grotesk", sans-serif;
}

.module-kpi-delta {
  color: #dce9ff;
  font-size: 0.9rem;
}

.module-kpi-card[data-tone="warning"] {
  border-color: rgba(255, 125, 145, 0.24);
  background: linear-gradient(145deg, rgba(255, 125, 145, 0.08), rgba(255, 255, 255, 0.03));
}

.module-kpi-card[data-tone="positive"] {
  border-color: rgba(80, 213, 183, 0.18);
}

.module-analytics-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.module-analytics-grid-secondary {
  align-items: start;
}

.module-panel {
  padding: 18px;
  display: grid;
  gap: 14px;
}

.module-funnel-list,
.module-trend-list,
.module-signal-list,
.module-rule-list {
  display: grid;
  gap: 12px;
}

.module-funnel-stage {
  padding: 14px 16px;
  display: grid;
  gap: 10px;
}

.module-funnel-head,
.module-signal-head,
.module-rule-head,
.content-item-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.module-funnel-head strong,
.module-signal-head strong,
.module-rule-head strong,
.content-item-head strong {
  margin-bottom: 0;
}

.module-funnel-note,
.module-signal-note,
.module-rule-note {
  color: var(--muted);
  line-height: 1.55;
}

.module-funnel-bar {
  width: 100%;
  height: 10px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.06);
}

.module-funnel-bar span,
.module-trend-bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(83, 167, 255, 0.68), rgba(141, 103, 255, 0.92), rgba(84, 230, 255, 0.62));
  box-shadow: 0 0 18px rgba(141, 103, 255, 0.18);
}

.module-trend-row {
  padding: 14px 16px;
  display: grid;
  gap: 10px;
}

.module-trend-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: baseline;
}

.module-trend-meta strong {
  margin-bottom: 0;
}

.module-trend-meta span:last-child {
  color: var(--muted);
  font-size: 0.92rem;
}

.module-trend-bar {
  height: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.module-signal-card,
.module-rule-card {
  padding: 14px 16px;
  display: grid;
  gap: 8px;
}

.module-signal-value,
.module-rule-owner {
  color: #dce9ff;
  font-size: 0.92rem;
}

.module-signal-card[data-tone="warning"],
.module-rule-card[data-tone="warning"] {
  border-color: rgba(255, 125, 145, 0.24);
}

.module-signal-card[data-tone="positive"],
.module-rule-card[data-tone="positive"] {
  border-color: rgba(80, 213, 183, 0.18);
}

.content-list {
  max-height: 620px;
  overflow: auto;
}

.content-item {
  padding: 16px 18px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  text-align: left;
  color: var(--text);
}

.content-item-project,
.content-item-node,
.content-item-output {
  display: grid;
  gap: 10px;
}

.content-item-project p,
.content-item-node p,
.content-item-output p {
  margin: 0;
}

.content-item-project .pill,
.content-item-node .pill,
.content-item-output .pill {
  padding: 8px 10px;
}

.content-item-project .content-item-meta span,
.content-item-output .content-item-meta span {
  color: var(--muted);
  font-size: 0.84rem;
}

.webhook-list-item {
  width: 100%;
  text-align: left;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  color: var(--text);
  display: grid;
  gap: 14px;
  cursor: pointer;
}

.webhook-item-bar,
.webhook-item-actions,
.webhook-item-meta {
  display: flex;
  align-items: center;
  gap: 10px;
}

.webhook-item-bar {
  justify-content: space-between;
}

.webhook-item-actions {
  flex-shrink: 0;
}

.webhook-item-meta {
  color: var(--muted);
  flex-wrap: wrap;
  font-size: 0.84rem;
}

.icon-button {
  min-width: 42px;
  height: 42px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(159, 181, 255, 0.12);
  color: var(--text);
  font-weight: 700;
  letter-spacing: 0.12em;
}

.context-menu {
  position: absolute;
  width: 168px;
  padding: 8px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(15, 23, 50, 0.98), rgba(6, 12, 30, 0.98));
  border: 1px solid rgba(159, 181, 255, 0.12);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
  z-index: 30;
  display: grid;
  gap: 6px;
}

.context-menu-item {
  min-height: 42px;
  padding: 10px 12px;
  border-radius: 12px;
  text-align: left;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
}

.context-menu-item.danger {
  color: #ffb2bb;
}

.danger-eyebrow {
  color: #ff7d91;
}

.webhook-empty-state {
  min-height: 180px;
  border-radius: 22px;
  border: 1px dashed rgba(159, 181, 255, 0.18);
  background: rgba(255, 255, 255, 0.03);
  display: grid;
  place-items: center;
  color: var(--muted);
  padding: 24px;
  text-align: center;
}

#webhookIndexList {
  display: grid;
  gap: 14px;
  overflow: visible;
  padding-bottom: 0;
}

.webhook-list-item.active {
  background: linear-gradient(135deg, rgba(83, 167, 255, 0.14), rgba(141, 103, 255, 0.2));
  border-color: rgba(83, 167, 255, 0.24);
}

.run-entry {
  border: 1px solid rgba(159, 181, 255, 0.1);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.04);
  padding: 14px 16px;
}

.run-entry summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  list-style: none;
}

.run-entry summary::-webkit-details-marker {
  display: none;
}

.run-entry-meta {
  color: var(--muted);
  margin: 12px 0;
}

.webhook-control-panel {
  display: grid;
  gap: 20px;
  margin-top: 18px;
}

.embedded-run-list {
  display: grid;
  gap: 10px;
  border-top: 1px solid rgba(159, 181, 255, 0.1);
  padding-top: 12px;
}

.embedded-run-row {
  border: 1px solid rgba(159, 181, 255, 0.1);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.03);
  padding: 12px 14px;
}

.embedded-run-row summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  list-style: none;
}

.embedded-run-row summary::-webkit-details-marker {
  display: none;
}

.embedded-run-row pre {
  margin: 12px 0 0;
  padding: 12px;
  border-radius: 14px;
  background: rgba(4, 9, 22, 0.82);
  color: #dfe8ff;
  white-space: pre-wrap;
}

.content-item.active {
  background: linear-gradient(135deg, rgba(83, 167, 255, 0.14), rgba(141, 103, 255, 0.2));
  border-color: rgba(83, 167, 255, 0.28);
}

.content-item-meta, .agent-editor-meta, .agent-editor-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

.agent-editor-actions {
  justify-content: space-between;
}

.agent-editor-actions select {
  width: auto;
  min-width: 160px;
}

.mapping-editor {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.mapping-edit-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
}

.run-log {
  display: grid;
  gap: 12px;
}

.run-log details {
  border: 1px solid rgba(66, 51, 41, 0.08);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.72);
  padding: 12px 14px;
}

.run-log summary {
  cursor: pointer;
  font-weight: 700;
}

.run-log pre {
  margin: 12px 0 0;
  padding: 14px;
  border-radius: 14px;
  background: #1f1a17;
  color: #f9ebd0;
  white-space: pre-wrap;
}

.studio-column {
  display: grid;
  gap: 14px;
}

.studio-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.view-panel {
  display: none;
}

.view-panel.active {
  display: block;
}

.builder-panel {
  display: grid;
  gap: 18px;
}

.builder-view {
  display: none;
}

.builder-view.active {
  display: block;
}

.card-grid, .builder-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.info-card, .input-card, .toggle-card {
  padding: 18px;
  background: var(--surface-strong);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
}

.toggle-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.full-span {
  grid-column: 1 / -1;
}

input, textarea, select {
  width: 100%;
  border-radius: var(--radius-md);
  border: 1px solid rgba(159, 181, 255, 0.14);
  background: rgba(255, 255, 255, 0.04);
  padding: 14px 16px;
  color: var(--text);
}

select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, rgba(245, 248, 255, 0.92) 50%),
    linear-gradient(135deg, rgba(245, 248, 255, 0.92) 50%, transparent 50%);
  background-position:
    calc(100% - 22px) calc(50% - 2px),
    calc(100% - 16px) calc(50% - 2px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 42px;
  color-scheme: dark;
}

select option,
select optgroup {
  background: #111a31;
  color: #f5f8ff;
}

textarea {
  resize: vertical;
  min-height: 170px;
}

.primary-button, .secondary-button, .nav-button, .builder-tab, .app-tile {
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.primary-button, .secondary-button, .builder-tab {
  padding: 13px 18px;
  border-radius: 14px;
  font-weight: 700;
}

.primary-button {
  color: #fff;
  background: linear-gradient(135deg, #6ec2ff, #9a82ff);
  box-shadow: 0 16px 28px rgba(108, 159, 255, 0.34);
}

.secondary-button, .builder-tab {
  background: rgba(117, 137, 214, 0.16);
  border: 1px solid rgba(179, 198, 255, 0.24);
  color: #f7faff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.primary-button:hover, .secondary-button:hover, .nav-button:hover, .builder-tab:hover, .app-tile:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 30px rgba(88, 102, 199, 0.2);
}

.feed-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.feed-list li, .stack-item {
  padding: 13px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(159, 181, 255, 0.08);
}

.stack-item strong {
  display: block;
  margin-bottom: 6px;
}

.console-log {
  min-height: 210px;
  margin-bottom: 14px;
}

.bubble {
  max-width: 86%;
  padding: 14px 16px;
  border-radius: 18px;
  line-height: 1.5;
}

.bubble.bot {
  background: rgba(255, 255, 255, 0.05);
}

.bubble.user {
  justify-self: end;
  background: linear-gradient(135deg, var(--brand), #ff8b4a);
  color: #fff;
}

.mapping-table {
  display: grid;
  gap: 12px;
}

.mapping-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
}

.mapping-meta {
  color: var(--muted);
  font-size: 0.88rem;
}

.confidence {
  padding: 8px 10px;
  border-radius: 999px;
  background: rgba(80, 213, 183, 0.12);
  color: #8df1d6;
  font-weight: 700;
  font-size: 0.8rem;
}

.error-text {
  min-height: 1.2rem;
  margin: 0;
  color: #ff9fa8;
}

.hidden {
  display: none !important;
}

.auth-layout-dark {
  display: grid;
  min-height: 100%;
  grid-template-columns: minmax(0, 1.24fr) minmax(340px, 0.68fr);
  align-items: stretch;
}

.auth-hero-card {
  min-height: 612px;
  display: grid;
  align-content: start;
  gap: 18px;
  background:
    radial-gradient(circle at top left, rgba(83, 167, 255, 0.14), transparent 28%),
    radial-gradient(circle at 78% 16%, rgba(84, 230, 255, 0.08), transparent 18%),
    radial-gradient(circle at 50% 22%, rgba(141, 103, 255, 0.16), transparent 34%),
    linear-gradient(180deg, rgba(15, 23, 50, 0.9), rgba(6, 12, 30, 0.96)),
    rgba(11, 19, 41, 0.82);
  overflow: hidden;
  position: relative;
}

.auth-hero-card::before {
  content: "";
  position: absolute;
  inset: 24px auto auto 24px;
  width: 220px;
  height: 220px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(83, 167, 255, 0.16), transparent 68%);
  filter: blur(10px);
  opacity: 0.7;
  pointer-events: none;
}

.auth-hero-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 18% 24%, rgba(255, 255, 255, 0.22) 0 1px, transparent 1.5px),
    radial-gradient(circle at 78% 16%, rgba(255, 255, 255, 0.18) 0 1px, transparent 1.5px),
    radial-gradient(circle at 65% 42%, rgba(141, 103, 255, 0.24) 0 1px, transparent 1.6px),
    radial-gradient(circle at 30% 76%, rgba(83, 167, 255, 0.2) 0 1px, transparent 1.6px);
  opacity: 0.55;
  pointer-events: none;
}

.auth-card-shell {
  background:
    linear-gradient(180deg, rgba(15, 23, 50, 0.92), rgba(6, 12, 30, 0.96)),
    rgba(11, 19, 41, 0.82);
}

.auth-form-grid {
  display: grid;
  gap: 12px;
}

.auth-brand-stage {
  position: relative;
  min-height: 214px;
  display: grid;
  place-items: center;
  border-radius: 28px;
  border: 1px solid rgba(159, 181, 255, 0.12);
  background:
    radial-gradient(circle at center, rgba(83, 167, 255, 0.14), transparent 30%),
    radial-gradient(circle at 52% 18%, rgba(141, 103, 255, 0.24), transparent 32%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.02));
  overflow: hidden;
}

.auth-brand-stage::before,
.auth-brand-stage::after {
  content: "";
  position: absolute;
  inset: 50%;
  border-radius: 999px;
  transform: translate(-50%, -50%);
  border: 1px solid rgba(159, 181, 255, 0.08);
}

.auth-brand-stage::before {
  width: 66%;
  height: 66%;
}

.auth-brand-stage::after {
  width: 84%;
  height: 84%;
}

.auth-brand-core {
  position: relative;
  z-index: 2;
  display: grid;
  justify-items: center;
  gap: 14px;
}

.auth-brand-mark {
  width: 116px;
  height: 116px;
  padding: 16px;
  border-radius: 34px;
  background:
    linear-gradient(145deg, rgba(83, 167, 255, 0.22), rgba(141, 103, 255, 0.2), rgba(84, 230, 255, 0.12));
  border: 1px solid rgba(159, 181, 255, 0.18);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.04) inset,
    0 20px 70px rgba(83, 167, 255, 0.24);
  animation: authMarkFloat 5.5s ease-in-out infinite;
}

.auth-brand-mark img {
  display: block;
  width: 100%;
  height: 100%;
}

.auth-brand-caption {
  display: grid;
  gap: 4px;
  justify-items: center;
  text-align: center;
}

.auth-brand-caption span {
  font-size: 0.76rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(84, 230, 255, 0.78);
}

.auth-brand-caption strong {
  font: 700 1rem "Space Grotesk", sans-serif;
  max-width: 280px;
}

.auth-brand-orbit {
  position: absolute;
  z-index: 1;
  padding: 9px 12px;
  border-radius: 999px;
  border: 1px solid rgba(159, 181, 255, 0.12);
  background: rgba(9, 17, 38, 0.8);
  color: #dce9ff;
  font-size: 0.78rem;
  font-weight: 600;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(14px);
}

.auth-brand-orbit-a { top: 22px; left: 38px; }
.auth-brand-orbit-b { top: 30px; right: 44px; }
.auth-brand-orbit-c { bottom: 34px; left: 56px; }
.auth-brand-orbit-d { bottom: 22px; right: 52px; }

.auth-brand-flow {
  position: absolute;
  inset: auto 24px 18px;
  display: flex;
  gap: 10px;
  justify-content: center;
}

.auth-brand-flow span {
  width: min(18vw, 120px);
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(83, 167, 255, 0.2), rgba(141, 103, 255, 0.88), rgba(84, 230, 255, 0.28));
  box-shadow: 0 0 24px rgba(141, 103, 255, 0.2);
  animation: authFlowPulse 1.9s ease-in-out infinite;
}

.auth-brand-flow span:nth-child(2) { animation-delay: 180ms; }
.auth-brand-flow span:nth-child(3) { animation-delay: 360ms; }
.auth-brand-flow span:nth-child(4) { animation-delay: 540ms; }

.auth-value-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr 1fr;
  gap: 16px;
}

.auth-highlight-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 14px;
}

.auth-highlight-card,
.auth-lane-card,
.auth-proof-metric {
  position: relative;
  z-index: 1;
  border-radius: 22px;
  border: 1px solid rgba(159, 181, 255, 0.12);
  background: rgba(255, 255, 255, 0.035);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.02);
}

.auth-highlight-card {
  padding: 18px;
  display: grid;
  gap: 10px;
  align-content: start;
}

.auth-highlight-card-featured {
  background:
    radial-gradient(circle at top left, rgba(84, 230, 255, 0.14), transparent 38%),
    linear-gradient(145deg, rgba(83, 167, 255, 0.16), rgba(141, 103, 255, 0.18), rgba(255, 255, 255, 0.03));
}

.auth-highlight-card-sky {
  background:
    radial-gradient(circle at top right, rgba(84, 230, 255, 0.12), transparent 30%),
    linear-gradient(180deg, rgba(17, 31, 66, 0.92), rgba(11, 20, 43, 0.9));
}

.auth-highlight-card-violet {
  background:
    radial-gradient(circle at top right, rgba(141, 103, 255, 0.16), transparent 30%),
    linear-gradient(180deg, rgba(22, 19, 58, 0.94), rgba(11, 20, 43, 0.9));
}

.auth-highlight-head {
  display: flex;
  align-items: center;
  gap: 10px;
}

.auth-highlight-icon {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #eff4ff;
  font-size: 0.95rem;
  font-weight: 700;
  background: linear-gradient(145deg, rgba(83, 167, 255, 0.2), rgba(141, 103, 255, 0.28));
  border: 1px solid rgba(159, 181, 255, 0.16);
  box-shadow: 0 10px 24px rgba(83, 167, 255, 0.16);
}

.auth-highlight-card strong,
.auth-lane-card strong,
.auth-proof-metric strong {
  font-family: "Space Grotesk", sans-serif;
}

.auth-highlight-card strong {
  font-size: 1rem;
  line-height: 1.25;
}

.auth-highlight-card > span:last-child,
.auth-lane-card > span:last-child {
  color: var(--muted);
  line-height: 1.55;
  font-size: 0.93rem;
}

.auth-highlight-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 2px;
}

.auth-highlight-tags span,
.auth-entry-pills span {
  padding: 8px 10px;
  border-radius: 999px;
  border: 1px solid rgba(159, 181, 255, 0.14);
  background: rgba(255, 255, 255, 0.045);
  color: #dce9ff;
  font-size: 0.8rem;
  font-weight: 600;
}

.auth-value-card,
.auth-system-card,
.auth-proof-metric {
  border-radius: 22px;
  border: 1px solid rgba(159, 181, 255, 0.12);
  background: rgba(255, 255, 255, 0.035);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.02);
}

.auth-value-card {
  padding: 20px;
  display: grid;
  gap: 12px;
  align-content: start;
}

.auth-value-card.featured {
  background: linear-gradient(145deg, rgba(83, 167, 255, 0.14), rgba(141, 103, 255, 0.16), rgba(255, 255, 255, 0.03));
}

.auth-value-card strong,
.auth-system-card strong,
.auth-proof-metric strong {
  font-family: "Space Grotesk", sans-serif;
  font-size: 1.05rem;
}

.auth-value-card span:last-child,
.auth-system-card span:last-child {
  color: var(--muted);
  line-height: 1.65;
}

.auth-system-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.auth-system-card {
  padding: 18px;
  display: grid;
  gap: 10px;
}

.auth-system-step {
  width: fit-content;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(83, 167, 255, 0.12);
  border: 1px solid rgba(83, 167, 255, 0.18);
  color: #9fd3ff;
  font-size: 0.76rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.auth-proof-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.auth-lane-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.auth-lane-card {
  padding: 14px 16px;
  display: grid;
  gap: 8px;
  background:
    linear-gradient(180deg, rgba(14, 25, 52, 0.9), rgba(9, 17, 37, 0.94));
}

.auth-proof-metric {
  padding: 14px 16px;
  display: grid;
  gap: 6px;
}

.auth-proof-metric span {
  color: rgba(84, 230, 255, 0.8);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.auth-entry-card,
#registerForm.auth-card-shell {
  padding: 20px;
  gap: 14px;
}

.auth-entry-card h2,
#registerForm h2 {
  font-size: clamp(1.7rem, 2vw, 2.15rem);
  line-height: 1.08;
}

.auth-entry-card .helper-text,
#registerForm .helper-text {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.5;
}

.auth-entry-pills {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.auth-entry-card .field,
#registerForm .field {
  gap: 6px;
}

.auth-entry-card .field span,
#registerForm .field span {
  font-size: 0.92rem;
}

.auth-entry-card input,
#registerForm input {
  padding: 12px 14px;
}

.auth-entry-card .primary-button,
.auth-entry-card .secondary-button,
#registerForm .primary-button,
#registerForm .secondary-button {
  padding: 12px 16px;
}

.auth-entry-card .error-text {
  margin: 0;
}

.full-button {
  width: 100%;
  justify-content: center;
}

.auth-divider {
  position: relative;
  text-align: center;
  color: var(--muted);
}

.auth-divider::before {
  content: "";
  position: absolute;
  inset: 50% 0 auto;
  height: 1px;
  background: rgba(159, 181, 255, 0.12);
}

.auth-divider span {
  position: relative;
  padding: 0 12px;
  background: rgba(12, 20, 42, 0.95);
}

.story-label {
  margin: 0;
  font-size: 0.76rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
}

.register-progress {
  display: flex;
  gap: 10px;
  align-items: center;
}

.register-dot {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  background: rgba(159, 181, 255, 0.2);
  border: 1px solid rgba(159, 181, 255, 0.18);
}

.register-dot.active {
  background: linear-gradient(135deg, var(--brand), var(--brand-deep));
  border-color: rgba(83, 167, 255, 0.3);
  box-shadow: 0 0 18px rgba(83, 167, 255, 0.28);
}

.register-step {
  display: none;
  gap: 16px;
}

.register-step.active {
  display: grid;
}

.register-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.dashboard-hero,
.summary-panel,
.sidebar-card,
.view-panel,
.info-card,
.summary-panel,
.app-tile,
.toggle-card {
  background:
    linear-gradient(180deg, rgba(15, 23, 50, 0.88), rgba(6, 12, 30, 0.94)),
    rgba(11, 19, 41, 0.82);
}

.summary-row {
  border-bottom: 1px solid rgba(159, 181, 255, 0.12);
}

.summary-row strong {
  text-align: right;
  overflow-wrap: anywhere;
}

.run-log details {
  border: 1px solid rgba(159, 181, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
}

.run-log pre {
  background: #09111f;
  color: #dce9ff;
}

.trend-list,
.nested-stack {
  display: grid;
  gap: 12px;
}

.trend-row {
  display: grid;
  gap: 8px;
}

.trend-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  color: var(--muted);
}

.trend-bar {
  height: 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.trend-bar span {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--brand), var(--brand-deep));
  box-shadow: 0 0 18px rgba(83, 167, 255, 0.3);
}

.stack-detail summary {
  list-style: none;
  cursor: pointer;
}

.stack-detail summary::-webkit-details-marker {
  display: none;
}

.stack-detail[open] {
  border-color: rgba(83, 167, 255, 0.22);
  background: linear-gradient(180deg, rgba(16, 26, 56, 0.96), rgba(9, 16, 37, 0.98));
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.detail-kpi {
  display: grid;
  gap: 6px;
  padding: 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(159, 181, 255, 0.08);
}

.detail-kpi span {
  color: var(--muted);
  font-size: 0.86rem;
}

.inline-form-row {
  margin-top: 16px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  align-items: end;
}

.inline-form-row .primary-button {
  width: 100%;
}

.nested-stack pre {
  margin: 12px 0 0;
  padding: 14px;
  border-radius: 14px;
  background: #09111f;
  color: #dce9ff;
  white-space: pre-wrap;
}

@media (max-width: 1100px) {
  .login-layout, .dashboard-hero, .main-grid, .card-grid, .builder-grid, .app-grid, .webhook-studio, .agent-grid, .auth-layout-dark, .workspace-shell, .workspace-home-grid, .workspace-detail-grid {
    grid-template-columns: 1fr;
    display: grid;
  }
  .workspace-sidebar {
    position: static;
  }
  .workspace-header,
  .workspace-panel-head {
    grid-template-columns: 1fr;
  }
  .workspace-project-grid,
  .workspace-project-stats,
  .workspace-metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .webhook-overview-grid,
  .compact-webhook-form {
    grid-template-columns: 1fr;
  }
  .feature-tile {
    grid-template-columns: 1fr;
  }
  .tile-paths {
    justify-content: start;
  }
  .sidebar { position: static; }
  .connector-path-grid {
    grid-template-columns: 1fr;
  }
  .inline-form-row,
  .detail-grid {
    grid-template-columns: 1fr;
  }
  .auth-value-grid,
  .auth-system-grid,
  .auth-highlight-grid,
  .auth-lane-grid,
  .auth-proof-strip {
    grid-template-columns: 1fr;
  }
  .module-overview-hero,
  .module-kpi-grid,
  .module-analytics-grid {
    grid-template-columns: 1fr;
  }
  .auth-brand-stage {
    min-height: 250px;
  }
  .auth-brand-orbit-a { top: 18px; left: 24px; }
  .auth-brand-orbit-b { top: 18px; right: 24px; }
  .auth-brand-orbit-c { bottom: 48px; left: 24px; }
  .auth-brand-orbit-d { bottom: 48px; right: 24px; }
  .auth-stack {
    width: min(520px, 100%);
  }
}

@media (max-width: 720px) {
  body {
    background:
      radial-gradient(circle at top center, rgba(83, 167, 255, 0.16), transparent 26%),
      linear-gradient(180deg, #040711 0%, #07101f 58%, #091426 100%);
  }
  .app-shell {
    width: 100%;
    padding: 12px 12px 36px;
  }
  .app-boot-splash {
    padding: 18px;
  }
  .app-boot-splash__card {
    padding: 28px 22px 24px;
    border-radius: 26px;
  }
  .app-boot-splash__mark {
    width: 84px;
    height: 84px;
    border-radius: 24px;
  }
  .topbar, .topbar-actions, .panel-head, .toolbar, .prompt-form {
    flex-direction: column;
    align-items: stretch;
  }
  .workspace-shell,
  .workspace-main,
  .workspace-home-grid,
  .workspace-detail-grid,
  .workspace-project-grid,
  .workspace-project-stats,
  .workspace-metric-grid,
  .workspace-header-actions {
    grid-template-columns: 1fr;
  }
  .workspace-sidebar,
  .workspace-main {
    gap: 14px;
  }
  .workspace-brand-card,
  .workspace-sidebar-section,
  .workspace-panel {
    border-radius: 22px;
    padding: 16px;
  }
  .workspace-route-chip,
  .workspace-search-shell {
    min-height: 52px;
  }
  .workspace-nav-button {
    grid-template-columns: 38px minmax(0, 1fr);
  }
  .workspace-nav-icon {
    width: 38px;
    height: 38px;
    border-radius: 12px;
  }
  .workspace-project-card {
    padding: 16px;
  }
  .workspace-project-header,
  .workspace-list-item-head {
    grid-template-columns: 1fr;
  }
  .topbar {
    position: sticky;
    top: 0;
    z-index: 10;
    padding: 12px;
    border-radius: 22px;
    background: linear-gradient(180deg, rgba(11, 19, 41, 0.96), rgba(6, 12, 30, 0.94));
    border: 1px solid rgba(159, 181, 255, 0.1);
    backdrop-filter: blur(18px);
  }
  .topbar .eyebrow,
  .hero-text,
  .helper-text,
  .mapping-meta,
  .sidebar-card h3,
  .panel-head .eyebrow {
    display: none;
  }
  .topbar h2 {
    font-size: 1.25rem;
  }
  .brand-lockup {
    gap: 10px;
  }
  .brand-mark,
  .tile-icon {
    width: 48px;
    height: 48px;
    border-radius: 16px;
  }
  .topbar-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }
  .topbar-actions .pill,
  .topbar-actions .secondary-button,
  .topbar-actions .primary-button {
    min-height: 50px;
    justify-content: center;
    border-radius: 18px;
    text-align: center;
  }
  .dashboard-hero {
    gap: 14px;
    margin-bottom: 18px;
  }
  .dashboard-hero-copy h3 {
    font-size: 1.4rem;
    line-height: 1.1;
  }
  .dashboard-hero-copy .hero-badges {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }
  .dashboard-hero-copy .hero-badges .pill:last-child {
    grid-column: 1 / -1;
  }
  .summary-panel {
    padding: 16px;
    gap: 8px;
  }
  .summary-row {
    grid-template-columns: 1fr;
    gap: 6px;
    padding: 10px 0;
  }
  .summary-row strong {
    text-align: left;
    font-size: 0.92rem;
  }
  .app-grid {
    gap: 14px;
  }
  .app-tile,
  .feature-tile {
    border-radius: 22px;
    padding: 18px;
    gap: 14px;
  }
  .app-tile strong {
    font-size: 1.05rem;
  }
  .app-tile p {
    display: none;
  }
  .tile-paths {
    justify-content: start;
  }
  .main-grid {
    gap: 14px;
  }
  .sidebar {
    gap: 12px;
  }
  .sidebar-card {
    padding: 10px;
    border-radius: 20px;
  }
  .sidebar-card:not(:first-child) {
    display: none;
  }
  .sidebar-card:first-child {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    white-space: nowrap;
    background: transparent;
    border: 0;
    box-shadow: none;
    padding: 0;
  }
  .sidebar-card:first-child .nav-button {
    min-width: 150px;
    min-height: 52px;
    text-align: center;
    border-radius: 999px;
    font-weight: 700;
  }
  .view-panel,
  .info-card,
  .login-card,
  .hero-card {
    padding: 16px;
    border-radius: 22px;
  }
  .webhook-overview-grid,
  .card-grid,
  .webhook-studio,
  .agent-grid,
  .builder-grid,
  .compact-webhook-form {
    gap: 14px;
  }
  .compact-webhook-form .input-card,
  .input-card,
  .toggle-card {
    padding: 12px;
    border-radius: 16px;
  }
  .compact-webhook-form .input-card span,
  .input-card span,
  .field span {
    font-size: 0.8rem;
  }
  input,
  textarea,
  select,
  .primary-button,
  .secondary-button,
  .nav-button,
  .builder-tab {
    min-height: 52px;
    border-radius: 18px;
  }
  textarea {
    min-height: 130px;
  }
  .webhook-list-item {
    padding: 12px 14px;
    gap: 10px;
    border-radius: 18px;
  }
  .detail-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin-top: 10px;
  }
  .detail-kpi {
    padding: 10px;
    border-radius: 12px;
  }
  .detail-kpi span {
    font-size: 0.72rem;
  }
  .detail-kpi strong {
    font-size: 0.82rem;
  }
  #selectedWebhookDetail .panel-head h4,
  .studio-head h4,
  .info-card h4,
  .panel-head h3 {
    font-size: 1rem;
    line-height: 1.2;
  }
  .webhook-studio .studio-column:nth-child(2),
  .webhook-studio .studio-column:nth-child(3),
  .connector-path-grid,
  .summary-list .summary-row:has(#destinationDocSummary),
  .summary-list .summary-row:has(#selectedWebhookLatest) {
    display: none;
  }
  .content-list {
    max-height: none;
  }
  .content-item {
    padding: 14px;
    border-radius: 16px;
  }
  .module-overview-shell,
  .module-panel,
  .module-kpi-card,
  .module-funnel-stage,
  .module-trend-row,
  .module-signal-card,
  .module-rule-card {
    padding-left: 14px;
    padding-right: 14px;
  }
  .module-overview-shell {
    padding-top: 16px;
    padding-bottom: 16px;
  }
  .agent-editor-actions {
    gap: 10px;
  }
  .run-entry,
  .embedded-run-row {
    padding: 12px;
  }
  .compact-webhook-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .feature-tile {
    padding: 20px;
  }
  .auth-hero-card {
    min-height: auto;
    gap: 18px;
  }
  .auth-brand-stage {
    min-height: 220px;
    border-radius: 24px;
  }
  .auth-brand-stage::before,
  .auth-brand-stage::after {
    display: none;
  }
  .auth-brand-mark {
    width: 108px;
    height: 108px;
    border-radius: 30px;
    padding: 15px;
  }
  .auth-brand-caption strong {
    font-size: 0.95rem;
  }
  .auth-brand-orbit {
    padding: 8px 11px;
    font-size: 0.74rem;
  }
  .auth-brand-orbit-a { top: 14px; left: 14px; }
  .auth-brand-orbit-b { top: 14px; right: 14px; }
  .auth-brand-orbit-c { bottom: 42px; left: 14px; }
  .auth-brand-orbit-d { bottom: 42px; right: 14px; }
  .auth-brand-flow {
    inset: auto 12px 14px;
    gap: 8px;
  }
  .auth-brand-flow span {
    width: min(18vw, 72px);
  }
  .auth-value-card,
  .auth-system-card,
  .auth-proof-metric {
    padding: 14px;
    border-radius: 18px;
  }
  .auth-value-card strong,
  .auth-system-card strong,
  .auth-proof-metric strong {
    font-size: 0.96rem;
  }
.mapping-row { grid-template-columns: 1fr; }
}

.webhook-list-item {
  padding: 8px 12px;
  gap: 4px;
  border-radius: 12px;
}

.webhook-item-bar {
  display: grid;
  grid-template-columns: minmax(140px, 1.1fr) auto auto auto auto auto;
  align-items: center;
  gap: 8px;
}

.webhook-primary {
  font-size: 0.92rem;
  line-height: 1.2;
}

.webhook-type,
.webhook-meta-text {
  font-size: 0.76rem;
  color: var(--muted);
  white-space: nowrap;
}

.webhook-health-inline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 700;
  border: 1px solid rgba(159, 181, 255, 0.12);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.03);
}

.webhook-health-inline.live {
  background: rgba(79, 214, 170, 0.14);
  border-color: rgba(79, 214, 170, 0.2);
  color: #8af0cd;
}

.webhook-health-inline.queued {
  background: rgba(255, 194, 92, 0.14);
  border-color: rgba(255, 194, 92, 0.2);
  color: #ffd88d;
}

.webhook-health-inline.error {
  background: rgba(255, 108, 132, 0.14);
  border-color: rgba(255, 108, 132, 0.2);
  color: #ffb7c6;
}

.webhook-health-inline.neutral {
  color: var(--muted);
}

.webhook-item-actions {
  justify-content: flex-end;
}

.embedded-run-list {
  margin-top: 4px;
  padding: 8px;
  gap: 8px;
  border-radius: 12px;
  border-top: 0;
  background: rgba(10, 16, 38, 0.96);
  box-shadow: inset 0 0 0 1px rgba(159, 181, 255, 0.08);
}

.embedded-run-line {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(130px, 1fr) auto auto;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: 12px;
  border: 1px solid rgba(159, 181, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  text-align: left;
}

.embedded-run-line:hover {
  border-color: rgba(83, 167, 255, 0.22);
  background: rgba(83, 167, 255, 0.08);
}

.embedded-run-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 92px;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: capitalize;
  border: 1px solid rgba(159, 181, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
}

.pill.queued,
.embedded-run-status.queued {
  background: rgba(255, 194, 92, 0.16);
  border-color: rgba(255, 194, 92, 0.24);
  color: #ffd88d;
}

.pill.error,
.embedded-run-status.error {
  background: rgba(255, 108, 132, 0.16);
  border-color: rgba(255, 108, 132, 0.22);
  color: #ffb7c6;
}

.embedded-empty {
  padding: 12px;
  border-radius: 14px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.03);
}

.modal-close-button {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  border: 1px solid rgba(159, 181, 255, 0.14);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font-weight: 800;
  font-size: 0.9rem;
}

.json-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(4, 8, 22, 0.72);
  backdrop-filter: blur(8px);
  animation: modalFadeIn 180ms ease;
}

.json-modal-card {
  width: min(1040px, 100%);
  max-height: min(86vh, 900px);
  overflow: auto;
  padding: 20px;
  border-radius: 24px;
  border: 1px solid rgba(159, 181, 255, 0.14);
  background: linear-gradient(180deg, rgba(16, 24, 56, 0.98), rgba(7, 13, 30, 0.98));
  box-shadow: 0 40px 90px rgba(0, 0, 0, 0.38);
  animation: modalLiftIn 220ms ease;
}

.json-modal-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.json-modal pre {
  min-height: 320px;
  margin: 0;
  padding: 16px;
  border-radius: 16px;
  background: rgba(4, 9, 22, 0.86);
  color: #dfe8ff;
  white-space: pre-wrap;
  overflow: auto;
}

.endpoint-modal-card {
  width: min(580px, 100%);
}

.danger-modal-card {
  width: min(560px, 100%);
  border-color: rgba(255, 108, 132, 0.22);
  box-shadow: 0 32px 90px rgba(88, 13, 29, 0.32);
}

.danger-callout {
  margin: 8px 0 18px;
  padding: 16px 18px;
  border-radius: 18px;
  border: 1px solid rgba(255, 108, 132, 0.18);
  background: linear-gradient(180deg, rgba(70, 14, 28, 0.34), rgba(33, 8, 14, 0.22));
}

.danger-callout strong {
  display: block;
  margin-bottom: 8px;
  color: #ffd9df;
}

.danger-callout p {
  margin: 0;
  color: #ffb7c6;
  line-height: 1.5;
}

.danger-button {
  min-height: 46px;
  padding: 0 18px;
  border-radius: 999px;
  background: linear-gradient(135deg, #ff5f7a, #d8315b);
  color: #fff6f8;
  font-weight: 800;
  box-shadow: 0 18px 34px rgba(148, 24, 54, 0.3);
}

.endpoint-copy-shell {
  margin: 10px 0 18px;
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(159, 181, 255, 0.12);
  overflow: auto;
}

.endpoint-copy-shell code {
  color: #dfe8ff;
  white-space: nowrap;
}

@keyframes modalFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes bootHaloDrift {
  0%,
  100% {
    transform: scale(0.96);
    opacity: 0.72;
  }
  50% {
    transform: scale(1.04);
    opacity: 1;
  }
}

@keyframes bootMarkFloat {
  0%,
  100% {
    transform: translateY(0);
    box-shadow:
      0 0 0 1px rgba(255, 255, 255, 0.03) inset,
      0 18px 48px rgba(46, 97, 186, 0.24);
  }
  50% {
    transform: translateY(-4px);
    box-shadow:
      0 0 0 1px rgba(255, 255, 255, 0.03) inset,
      0 24px 56px rgba(46, 97, 186, 0.3);
  }
}

@keyframes bootPulse {
  0%,
  100% {
    opacity: 0.26;
    transform: scaleX(0.88);
  }
  50% {
    opacity: 1;
    transform: scaleX(1.08);
  }
}

@keyframes authMarkFloat {
  0%,
  100% {
    transform: translateY(0);
    box-shadow:
      0 0 0 1px rgba(255, 255, 255, 0.04) inset,
      0 20px 70px rgba(83, 167, 255, 0.24);
  }
  50% {
    transform: translateY(-8px);
    box-shadow:
      0 0 0 1px rgba(255, 255, 255, 0.05) inset,
      0 28px 82px rgba(83, 167, 255, 0.3);
  }
}

@keyframes authFlowPulse {
  0%,
  100% {
    opacity: 0.38;
    transform: scaleX(0.92);
  }
  50% {
    opacity: 1;
    transform: scaleX(1);
  }
}

@keyframes modalLiftIn {
  from {
    opacity: 0;
    transform: translateY(10px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@media (max-width: 1080px) {
  .webhook-item-bar {
    grid-template-columns: minmax(0, 1fr) auto auto;
    row-gap: 8px;
  }

  .webhook-type,
  .webhook-meta-text {
    font-size: 0.74rem;
  }

  .embedded-run-line {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .json-modal-grid {
    grid-template-columns: 1fr;
  }
}

/* Final webhook density overrides */
.card-grid.webhook-overview-grid,
.webhook-inventory-shell {
  display: block;
  width: 100%;
}

.webhook-inventory-shell {
  padding: 18px;
  border-radius: var(--radius-lg);
  background: var(--surface-strong);
  border: 1px solid var(--line);
}

.context-menu {
  position: fixed;
}

#webhookIndexList {
  gap: 8px;
}

.webhook-list-item {
  padding: 0;
  gap: 0;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  overflow: visible;
}

.webhook-item-bar {
  display: grid;
  grid-template-columns: minmax(220px, 1.9fr) 110px 100px 90px 120px 130px 56px;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
}

.webhook-primary {
  font-size: 0.91rem;
}

.webhook-type,
.webhook-meta-text {
  font-size: 0.75rem;
}

.webhook-health-inline {
  min-height: 22px;
  padding: 0 8px;
  font-size: 0.71rem;
  border-radius: 999px;
  white-space: nowrap;
}

.webhook-health-inline.neutral {
  background: transparent;
  border-color: rgba(159, 181, 255, 0.08);
}

.icon-button {
  min-width: 38px;
  height: 38px;
}

.embedded-run-list {
  margin-top: 0;
  padding: 6px 8px;
  border-radius: 0 0 8px 8px;
  background: rgba(8, 14, 34, 0.98);
  box-shadow: inset 0 0 0 1px rgba(159, 181, 255, 0.08);
}

.embedded-run-line {
  grid-template-columns: minmax(120px, 1fr) auto auto;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 10px;
}

.endpoint-inline {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  min-width: 0;
}

.endpoint-inline strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mini-copy-button {
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  border: 1px solid rgba(159, 181, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font-size: 0.72rem;
  font-weight: 700;
  flex-shrink: 0;
}

.embedded-empty-inline {
  padding: 6px 4px 2px;
  color: var(--muted);
  font-size: 0.76rem;
}

.webhook-item-actions {
  justify-content: flex-end;
  position: relative;
}

.webhook-inline-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  width: 164px;
  padding: 8px;
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(15, 23, 50, 0.98), rgba(6, 12, 30, 0.98));
  border: 1px solid rgba(159, 181, 255, 0.12);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
  display: grid;
  gap: 6px;
  z-index: 20;
}

.workspace-main {
  gap: 18px;
}

.workspace-header {
  grid-template-columns: max-content minmax(320px, 1fr) max-content;
  gap: 16px;
}

.workspace-header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
}

.workspace-release-badge,
.workspace-health-pill,
.workspace-logout-button {
  display: none;
}

.workspace-header-primary,
.workspace-panel-actions .primary-button,
.workspace-panel-actions .secondary-button {
  min-height: 42px;
  padding: 0 18px;
  border-radius: 18px;
  font-size: 0.92rem;
}

.workspace-panel-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.workspace-user-pill {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 38px;
  align-items: center;
  gap: 12px;
  min-width: 150px;
  padding: 8px 8px 8px 14px;
  border-radius: 18px;
  border: 1px solid rgba(159, 181, 255, 0.12);
  background:
    radial-gradient(circle at top right, rgba(130, 111, 255, 0.22), transparent 48%),
    rgba(20, 27, 56, 0.96);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.02);
}

.workspace-user-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.workspace-user-copy small {
  color: rgba(152, 165, 207, 0.72);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.54rem;
}

.workspace-user-copy strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font: 700 1rem "Space Grotesk", sans-serif;
}

.workspace-user-avatar {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #fff;
  font: 700 0.95rem "Space Grotesk", sans-serif;
  background: linear-gradient(135deg, rgba(146, 89, 255, 0.98), rgba(109, 178, 255, 0.92));
  box-shadow: 0 10px 24px rgba(120, 93, 255, 0.24);
}

.workspace-panel {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 78% 0%, rgba(183, 103, 255, 0.14), transparent 26%),
    radial-gradient(circle at 50% 100%, rgba(95, 172, 255, 0.08), transparent 34%),
    linear-gradient(180deg, rgba(17, 20, 52, 0.98), rgba(10, 14, 35, 0.98));
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    inset 0 -1px 0 rgba(93, 121, 197, 0.08);
}

.workspace-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 18% 24%, rgba(255, 255, 255, 0.11) 0 1px, transparent 1.5px),
    radial-gradient(circle at 72% 36%, rgba(255, 255, 255, 0.08) 0 1px, transparent 1.5px),
    radial-gradient(circle at 58% 18%, rgba(255, 255, 255, 0.06) 0 1px, transparent 1.5px);
  opacity: 0.22;
  pointer-events: none;
}

.workspace-panel > * {
  position: relative;
  z-index: 1;
}

.workspace-project-grid {
  grid-template-columns: repeat(auto-fit, minmax(246px, 272px));
  justify-content: start;
  gap: 14px;
}

.workspace-project-card {
  gap: 12px;
  min-height: 188px;
  padding: 14px;
  border-radius: 24px;
  background:
    radial-gradient(circle at top left, rgba(85, 166, 255, 0.08), transparent 34%),
    linear-gradient(180deg, rgba(32, 38, 82, 0.88), rgba(23, 28, 63, 0.94));
  box-shadow:
    0 16px 34px rgba(0, 0, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.055);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.workspace-project-card:hover,
.workspace-project-card:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(133, 190, 255, 0.28);
  box-shadow:
    0 24px 48px rgba(0, 0, 0, 0.28),
    0 0 0 1px rgba(107, 171, 255, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.workspace-project-card.active {
  border-color: rgba(94, 183, 255, 0.32);
  background:
    radial-gradient(circle at top left, rgba(83, 167, 255, 0.22), transparent 34%),
    linear-gradient(180deg, rgba(43, 61, 101, 0.96), rgba(28, 42, 80, 0.98));
}

.workspace-project-meta {
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 12px;
  align-items: center;
}

.workspace-project-meta .hero-badges {
  flex-wrap: wrap;
  gap: 8px;
}

.workspace-project-chip {
  justify-content: flex-start;
  padding: 7px 11px;
  font-size: 0.74rem;
  color: #eef4ff;
  background: rgba(255, 255, 255, 0.06);
}

.workspace-project-menu {
  min-width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  border: 1px solid rgba(159, 181, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  color: rgba(241, 245, 255, 0.88);
  font: 700 0.9rem "Space Grotesk", sans-serif;
}

.workspace-project-header {
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.workspace-project-avatar {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #fff;
  font: 700 1rem "Space Grotesk", sans-serif;
  background: linear-gradient(135deg, rgba(168, 100, 255, 0.98), rgba(100, 198, 255, 0.92));
}

.workspace-project-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.workspace-project-copy strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.98rem;
}

.workspace-project-description {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.84rem;
}

.workspace-project-stats {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.workspace-project-stat {
  padding: 10px 10px 8px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  box-shadow: inset 0 0 0 1px rgba(159, 181, 255, 0.08);
}

.workspace-project-stat strong {
  font-size: 1.06rem;
}

.workspace-project-stat span {
  color: rgba(214, 224, 255, 0.82);
  text-transform: none;
  letter-spacing: 0;
  font-size: 0.72rem;
}

.workspace-project-progress {
  width: 100%;
  height: 4px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.08);
}

.workspace-project-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(101, 201, 255, 0.96), rgba(226, 108, 255, 0.96));
  box-shadow: 0 0 18px rgba(146, 104, 255, 0.42);
}

.workspace-project-footer {
  align-items: center;
  color: rgba(189, 201, 236, 0.86);
  font-size: 0.78rem;
}

.workspace-pinned-list {
  gap: 10px;
}

.workspace-pinned-app {
  grid-template-columns: 34px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  border-radius: 18px;
}

.workspace-pinned-app-avatar {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  color: #f7f8ff;
  font: 700 0.7rem "Space Grotesk", sans-serif;
  background: rgba(111, 126, 208, 0.72);
}

.workspace-pinned-app-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.workspace-pinned-app-copy strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.workspace-pinned-app-copy small {
  display: none;
}

.workspace-home-grid {
  grid-template-columns: minmax(0, 1fr);
}

.workspace-command-center {
  gap: 24px;
  background:
    radial-gradient(circle at top right, rgba(208, 103, 255, 0.18), transparent 28%),
    radial-gradient(circle at bottom left, rgba(96, 177, 255, 0.12), transparent 32%),
    linear-gradient(180deg, rgba(22, 23, 58, 0.98), rgba(13, 18, 43, 0.98));
}

.workspace-command-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(320px, 0.92fr);
  gap: 18px;
  align-items: start;
}

.workspace-command-main {
  display: grid;
  gap: 14px;
}

.workspace-command-main .workspace-metric-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.workspace-metric-card {
  min-height: 70px;
  padding: 14px 16px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(40, 34, 76, 0.82), rgba(20, 24, 51, 0.92));
}

.workspace-metric-card strong {
  font-size: 1.65rem;
}

.workspace-metric-card span {
  color: rgba(177, 186, 222, 0.82);
  font-size: 0.68rem;
}

.workspace-metric-card small {
  display: none;
}

.workspace-command-rows {
  display: grid;
  gap: 0;
  margin-top: 4px;
}

.workspace-command-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 16px;
  align-items: center;
  padding: 10px 0;
  border-top: 1px solid rgba(159, 181, 255, 0.1);
}

.workspace-command-row:first-child {
  border-top: 0;
}

.workspace-command-row span {
  color: #eef3ff;
  font-size: 0.92rem;
}

.workspace-command-row strong {
  color: #f7f8ff;
  font: 700 0.98rem "Space Grotesk", sans-serif;
}

.workspace-command-side-shell {
  padding: 16px;
  border-radius: 24px;
  background: rgba(7, 14, 33, 0.86);
  box-shadow: inset 0 0 0 1px rgba(88, 123, 226, 0.18);
}

.workspace-command-side-card {
  display: grid;
  gap: 24px;
  min-height: 180px;
  padding: 18px;
  border-radius: 20px;
  background: linear-gradient(180deg, rgba(35, 37, 67, 0.88), rgba(24, 27, 51, 0.96));
  box-shadow: inset 0 0 0 1px rgba(159, 181, 255, 0.08);
}

.workspace-command-side-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 14px;
  align-items: center;
}

.workspace-command-side-head h4 {
  font-size: 1.02rem;
}

.workspace-command-side-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: rgba(200, 211, 244, 0.86);
  white-space: nowrap;
}

.workspace-command-side-status::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(122, 117, 255, 0.96), rgba(100, 201, 255, 0.96));
  box-shadow: 0 0 14px rgba(119, 142, 255, 0.42);
}

.workspace-focus-copy {
  align-content: center;
}

.workspace-focus-copy strong {
  font-size: 1.08rem;
}

@media (max-width: 1240px) {
  .workspace-header {
    grid-template-columns: 1fr;
  }

  .workspace-header-actions {
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .workspace-command-layout {
    grid-template-columns: 1fr;
  }

  .workspace-command-main .workspace-metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .workspace-home-action-strip,
  #dashboardScreen .workspace-home-action-strip {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .workspace-header-primary {
    width: 100%;
  }

  .workspace-user-pill {
    width: 100%;
    min-width: 0;
  }

  .workspace-panel-actions {
    justify-content: stretch;
  }

  .workspace-panel-actions .primary-button,
  .workspace-panel-actions .secondary-button {
    width: 100%;
  }

  .workspace-project-grid,
  .workspace-command-main .workspace-metric-grid {
    grid-template-columns: 1fr;
  }

  .workspace-command-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }
}

.workspace-sidebar {
  gap: 16px;
}

.workspace-brand-card {
  background:
    radial-gradient(circle at top left, rgba(121, 202, 255, 0.18), transparent 36%),
    radial-gradient(circle at top right, rgba(176, 118, 255, 0.14), transparent 34%),
    linear-gradient(180deg, rgba(28, 38, 74, 0.98), rgba(16, 23, 47, 0.98));
}

.workspace-sidebar-toggle {
  width: 44px;
  height: 44px;
  border-radius: 16px;
  border-color: rgba(199, 215, 255, 0.24);
  background:
    linear-gradient(180deg, rgba(67, 82, 142, 0.92), rgba(31, 40, 80, 0.92));
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.06) inset,
    0 12px 24px rgba(30, 36, 74, 0.24);
}

.workspace-sidebar-toggle:hover,
.workspace-nav-button:hover,
.content-item:hover,
.workspace-project-card:hover {
  transform: translateY(-1px);
}

.workspace-nav-button {
  min-height: 66px;
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(31, 38, 72, 0.96), rgba(18, 24, 48, 0.96));
  box-shadow: inset 0 0 0 1px rgba(188, 206, 255, 0.08);
}

.workspace-nav-button.active {
  border-color: rgba(208, 226, 255, 0.34);
  background:
    radial-gradient(circle at left center, rgba(173, 106, 255, 0.18), transparent 30%),
    linear-gradient(135deg, rgba(95, 113, 209, 0.92), rgba(45, 55, 109, 0.96));
}

.workspace-nav-icon {
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.08),
    0 10px 22px rgba(55, 71, 132, 0.18);
}

.workspace-nav-button:nth-child(1) .workspace-nav-icon {
  background: linear-gradient(135deg, rgba(95, 184, 255, 0.36), rgba(104, 132, 255, 0.38));
}

.workspace-nav-button:nth-child(2) .workspace-nav-icon {
  background: linear-gradient(135deg, rgba(134, 126, 255, 0.38), rgba(205, 111, 255, 0.34));
}

.workspace-nav-button:nth-child(3) .workspace-nav-icon {
  background: linear-gradient(135deg, rgba(96, 225, 206, 0.32), rgba(99, 149, 255, 0.34));
}

.workspace-nav-button:nth-child(4) .workspace-nav-icon {
  background: linear-gradient(135deg, rgba(255, 179, 97, 0.3), rgba(122, 165, 255, 0.34));
}

.workspace-user-shell {
  position: relative;
}

.workspace-user-pill {
  width: 100%;
}

.workspace-user-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  min-width: 220px;
  padding: 8px;
  border-radius: 18px;
  border: 1px solid rgba(159, 181, 255, 0.12);
  background:
    radial-gradient(circle at top right, rgba(147, 92, 255, 0.2), transparent 44%),
    linear-gradient(180deg, rgba(20, 24, 53, 0.98), rgba(9, 14, 34, 0.98));
  box-shadow: 0 26px 60px rgba(0, 0, 0, 0.38);
  display: grid;
  gap: 6px;
  z-index: 30;
}

.workspace-user-dropdown-item {
  width: 100%;
  min-height: 42px;
  padding: 0 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid transparent;
  color: var(--text);
  text-align: left;
  font-weight: 600;
}

.workspace-user-dropdown-item:hover {
  border-color: rgba(159, 181, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
}

.workspace-user-dropdown-item.danger {
  color: #ffb7c6;
}

.workspace-user-avatar {
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
}

.workspace-user-avatar.has-image {
  box-shadow:
    0 0 0 2px rgba(255, 255, 255, 0.08) inset,
    0 10px 24px rgba(120, 93, 255, 0.24);
}

.content-list {
  scrollbar-width: thin;
}

#agentProjectsList,
#agentRunsList,
#agentOutputsList,
#contentItemsList {
  max-height: none;
}

.agent-plan-summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid rgba(159, 181, 255, 0.1);
  background:
    radial-gradient(circle at top right, rgba(125, 108, 255, 0.16), transparent 46%),
    rgba(255, 255, 255, 0.035);
}

.agent-plan-summary small {
  display: block;
  margin-bottom: 4px;
  color: rgba(175, 189, 225, 0.72);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.58rem;
}

.agent-plan-summary strong {
  font: 700 1rem "Space Grotesk", sans-serif;
}

.content-item-library,
.project-insight-card,
.output-review-card {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at top right, rgba(137, 97, 255, 0.12), transparent 34%),
    radial-gradient(circle at top left, rgba(96, 190, 255, 0.12), transparent 28%),
    linear-gradient(180deg, rgba(39, 48, 89, 0.96), rgba(20, 26, 52, 0.98));
  border-color: rgba(176, 203, 255, 0.14);
}

.content-item-library::before,
.project-insight-card::before,
.output-review-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 20% 28%, rgba(255, 255, 255, 0.12) 0 1px, transparent 1.5px),
    radial-gradient(circle at 76% 36%, rgba(255, 255, 255, 0.08) 0 1px, transparent 1.5px);
  opacity: 0.18;
  pointer-events: none;
}

.content-item > *,
.project-insight-card > *,
.output-review-card > * {
  position: relative;
  z-index: 1;
}

.project-insight-card {
  cursor: pointer;
  gap: 12px;
}

.project-insight-card.active,
.output-review-card.active,
.content-item.active {
  border-color: rgba(152, 208, 255, 0.28);
  background:
    radial-gradient(circle at top left, rgba(96, 190, 255, 0.16), transparent 32%),
    radial-gradient(circle at top right, rgba(196, 113, 255, 0.16), transparent 34%),
    linear-gradient(180deg, rgba(48, 61, 108, 0.98), rgba(24, 31, 61, 0.98));
}

.project-insight-title,
.project-insight-menu {
  display: flex;
  align-items: center;
  gap: 10px;
}

.project-insight-title {
  min-width: 0;
  flex-wrap: wrap;
}

.project-insight-title strong {
  font-size: 1rem;
  color: #ffffff;
}

.project-insight-menu {
  position: relative;
  margin-left: auto;
}

.project-insight-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.project-insight-stats div {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  box-shadow: inset 0 0 0 1px rgba(159, 181, 255, 0.08);
}

.project-insight-stats span {
  display: block;
  margin-bottom: 4px;
  color: rgba(177, 189, 224, 0.78);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.project-insight-stats strong {
  font: 700 1.2rem "Space Grotesk", sans-serif;
  color: #ffffff;
}

.project-inline-menu {
  top: calc(100% + 6px);
  right: 0;
}

.content-item-library p,
.project-insight-card p {
  color: rgba(214, 223, 247, 0.86);
}

.project-insight-card .content-item-meta span,
.output-review-card .content-item-meta span,
.project-queue-meta {
  color: rgba(219, 227, 248, 0.78);
}

.project-run-entry {
  background:
    radial-gradient(circle at top right, rgba(133, 110, 255, 0.14), transparent 32%),
    rgba(255, 255, 255, 0.05);
}

.module-operations-shell {
  display: grid;
  grid-template-columns: minmax(0, 0.94fr) minmax(0, 1.06fr);
  gap: 16px;
}

.module-review-panel,
.module-queue-panel {
  gap: 14px;
}

.module-queue-list,
.module-review-list {
  display: grid;
  gap: 12px;
}

.project-queue-entry {
  padding: 0;
  overflow: hidden;
}

.project-queue-entry summary {
  display: grid;
  gap: 10px;
  padding: 14px 16px;
}

.project-queue-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 12px;
  align-items: start;
}

.project-queue-head strong {
  color: #f7f9ff;
}

.project-queue-meta {
  color: rgba(213, 222, 246, 0.8);
  font-size: 0.84rem;
}

.project-queue-progress {
  display: grid;
  gap: 8px;
}

.project-queue-progress-bar {
  height: 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.project-queue-progress-bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(90, 205, 255, 0.96), rgba(197, 106, 255, 0.96));
  box-shadow: 0 0 18px rgba(156, 121, 255, 0.28);
}

.project-queue-progress-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  color: rgba(210, 219, 243, 0.82);
  font-size: 0.82rem;
}

.output-review-card {
  padding: 0;
}

.output-review-card summary {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  cursor: pointer;
  list-style: none;
  padding: 16px 18px 10px;
}

.output-review-card summary::-webkit-details-marker {
  display: none;
}

.output-review-card .content-item-meta,
.output-review-grid {
  padding: 0 18px 16px;
}

.output-review-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.output-review-actions-inline {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  padding: 0 18px 18px;
}

.output-review-actions-inline button {
  min-height: 38px;
  padding: 0 10px;
  border-radius: 12px;
  font-size: 0.82rem;
}

.module-output-inspector {
  display: grid;
  gap: 12px;
  padding: 14px 16px 0;
  border-top: 1px solid rgba(176, 203, 255, 0.1);
}

.agent-output-actions {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
}

.agent-output-actions .primary-button,
.agent-output-actions .secondary-button {
  width: 100%;
  min-height: 40px;
  padding: 0 10px;
  font-size: 0.84rem;
}

.agent-output-actions button:disabled {
  opacity: 0.48;
  cursor: not-allowed;
}

.agent-workspace-grid {
  align-items: start;
}

#agentOutputMetrics {
  margin: 0;
  padding: 14px;
  border-radius: 14px;
  background: rgba(9, 14, 31, 0.82);
}

.revenue-workspace-shell,
.revenue-panel {
  gap: 14px;
}

.revenue-workspace-shell {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  padding: 18px;
  min-height: 0;
  height: 100%;
  overflow: hidden;
  background:
    radial-gradient(circle at top right, rgba(77, 196, 187, 0.12), transparent 28%),
    radial-gradient(circle at top left, rgba(150, 113, 255, 0.14), transparent 32%),
    linear-gradient(180deg, rgba(23, 31, 60, 0.98), rgba(11, 18, 37, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 24px 46px rgba(6, 10, 24, 0.28);
}

.revenue-shell-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 1.1fr) auto;
  flex-wrap: wrap;
  gap: 12px;
  align-items: start;
}

.revenue-shell-alerts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  min-width: 0;
}

.revenue-alert-card {
  display: grid;
  gap: 6px;
  min-width: 0;
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid rgba(157, 181, 240, 0.14);
  background: linear-gradient(180deg, rgba(24, 33, 63, 0.94), rgba(14, 20, 39, 0.96));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.revenue-alert-button {
  appearance: none;
  width: 100%;
  text-align: left;
  cursor: pointer;
  align-content: start;
  min-height: 0;
  padding: 12px 14px;
}

.revenue-alert-button:hover,
.revenue-alert-button:focus-visible {
  border-color: rgba(164, 197, 255, 0.3);
  filter: brightness(1.04);
  transform: translateY(-1px);
}

.revenue-alert-card strong {
  color: #f4f7ff;
  font: 700 0.86rem "Space Grotesk", sans-serif;
  letter-spacing: 0.02em;
}

.revenue-alert-card span {
  color: rgba(208, 218, 245, 0.82);
  font-size: 0.79rem;
  line-height: 1.45;
}

.revenue-alert-card[data-tone="live"],
.revenue-alert-card[data-tone="positive"] {
  border-color: rgba(104, 232, 189, 0.28);
  background: linear-gradient(180deg, rgba(18, 47, 52, 0.92), rgba(13, 25, 34, 0.98));
}

.revenue-alert-card[data-tone="warning"] {
  border-color: rgba(255, 193, 112, 0.28);
  background: linear-gradient(180deg, rgba(53, 37, 24, 0.94), rgba(22, 18, 28, 0.98));
}

.revenue-shell-head .hero-badges {
  flex-wrap: wrap;
  justify-content: flex-end;
  max-width: 100%;
}

.revenue-module-tabbar {
  display: flex;
  flex-wrap: nowrap;
  gap: 4px;
  margin-top: 10px;
  margin-bottom: 2px;
  overflow-x: auto;
  overflow-y: hidden;
  align-items: end;
  padding: 10px 12px 0;
  border-radius: 20px 20px 0 0;
  border: 1px solid rgba(168, 193, 255, 0.08);
  border-bottom-color: rgba(255, 255, 255, 0.04);
  background:
    linear-gradient(180deg, rgba(18, 25, 47, 0.94), rgba(11, 17, 33, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.03),
    inset 0 -1px 0 rgba(0, 0, 0, 0.22);
  scrollbar-width: thin;
  position: sticky;
  top: 0;
  z-index: 3;
}

.revenue-module-tab {
  display: inline-flex;
  flex: 1 1 0;
  align-items: center;
  gap: 8px;
  min-height: 52px;
  min-width: 132px;
  padding: 0 12px;
  margin-bottom: -1px;
  border-radius: 15px 15px 0 0;
  border: 1px solid rgba(210, 219, 239, 0.2);
  border-bottom-color: rgba(72, 82, 108, 0.82);
  background:
    linear-gradient(180deg, rgba(172, 181, 203, 0.28), rgba(86, 96, 124, 0.3) 48%, rgba(33, 40, 63, 0.88));
  color: rgba(236, 241, 252, 0.94);
  font: 700 0.84rem "Space Grotesk", sans-serif;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease, color 160ms ease, box-shadow 160ms ease, filter 160ms ease;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.3),
    inset 0 -1px 0 rgba(21, 27, 44, 0.46),
    0 10px 18px rgba(6, 10, 24, 0.16);
}

.revenue-module-tab:hover {
  color: #ffffff;
  border-color: rgba(228, 235, 255, 0.32);
  transform: translateY(-1px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.42),
    inset 0 -1px 0 rgba(22, 28, 45, 0.38),
    0 14px 24px rgba(7, 11, 28, 0.2);
  filter: brightness(1.05);
}

.revenue-module-tab.active {
  color: #16233f;
  border-color: rgba(242, 247, 255, 0.78);
  border-bottom-color: rgba(225, 232, 247, 0.08);
  background:
    linear-gradient(180deg, rgba(251, 253, 255, 0.98), rgba(211, 221, 239, 0.94) 46%, rgba(124, 140, 178, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.92),
    inset 0 -1px 0 rgba(76, 88, 117, 0.42),
    0 16px 26px rgba(9, 14, 30, 0.2);
  transform: translateY(1px);
}

.revenue-module-tab-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  color: inherit;
}

.revenue-module-tab-icon svg {
  width: 18px;
  height: 18px;
}

.revenue-module-tab-copy {
  display: grid;
  gap: 2px;
  text-align: left;
  min-width: 0;
}

.revenue-module-tab-copy small {
  color: rgba(213, 223, 246, 0.72);
  font: 600 0.62rem "Inter", sans-serif;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.revenue-module-tab.active .revenue-module-tab-copy small {
  color: rgba(34, 48, 80, 0.68);
}

.revenue-module-tab-copy strong {
  color: inherit;
  font: 700 0.94rem "Space Grotesk", sans-serif;
  letter-spacing: 0;
}

.revenue-tab-panel {
  display: grid;
  gap: 16px;
  align-content: start;
  min-height: 0;
  height: 100%;
  overflow-y: auto;
  overflow-x: hidden;
  padding-right: 6px;
  scrollbar-width: auto;
  scrollbar-color: rgba(201, 209, 226, 0.9) rgba(19, 26, 46, 0.82);
}

.workspace-main,
.revenue-module-tabbar,
.revenue-tab-panel,
.content-list {
  scrollbar-gutter: stable;
}

.workspace-main::-webkit-scrollbar,
.revenue-module-tabbar::-webkit-scrollbar,
.revenue-tab-panel::-webkit-scrollbar,
.content-list::-webkit-scrollbar {
  width: 14px;
  height: 14px;
}

.workspace-main::-webkit-scrollbar-track,
.revenue-module-tabbar::-webkit-scrollbar-track,
.revenue-tab-panel::-webkit-scrollbar-track,
.content-list::-webkit-scrollbar-track {
  border-radius: 999px;
  border: 1px solid rgba(205, 214, 235, 0.08);
  background:
    linear-gradient(180deg, rgba(47, 56, 80, 0.86), rgba(18, 24, 41, 0.96));
  box-shadow:
    inset 0 2px 5px rgba(0, 0, 0, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.workspace-main::-webkit-scrollbar-thumb,
.revenue-module-tabbar::-webkit-scrollbar-thumb,
.revenue-tab-panel::-webkit-scrollbar-thumb,
.content-list::-webkit-scrollbar-thumb {
  border-radius: 999px;
  border: 2px solid rgba(22, 28, 45, 0.82);
  background:
    linear-gradient(180deg, rgba(248, 251, 255, 0.95), rgba(178, 190, 216, 0.92) 44%, rgba(102, 114, 142, 0.96));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.88),
    inset 0 -1px 0 rgba(67, 79, 108, 0.48),
    0 3px 8px rgba(0, 0, 0, 0.22);
}

.workspace-main::-webkit-scrollbar-thumb:hover,
.revenue-module-tabbar::-webkit-scrollbar-thumb:hover,
.revenue-tab-panel::-webkit-scrollbar-thumb:hover,
.content-list::-webkit-scrollbar-thumb:hover {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(197, 208, 231, 0.95) 44%, rgba(118, 131, 160, 0.98));
}

.revenue-tab-panel > *,
.revenue-workspace-grid > *,
.revenue-report-grid > *,
.revenue-pipeline-shell > *,
.revenue-ops-grid > *,
.revenue-priority-grid > *,
.revenue-chart-grid > *,
.revenue-insight-grid > *,
.revenue-report-cards > * {
  min-width: 0;
}

.revenue-tab-panel > .module-panel,
.revenue-tab-panel > .revenue-pipeline-shell > .module-panel,
.revenue-tab-panel > .revenue-report-grid > .module-panel,
.revenue-tab-panel > .revenue-workspace-grid > .module-panel,
.revenue-tab-panel > .revenue-ops-grid > .module-panel {
  border: 1px solid rgba(180, 202, 255, 0.08);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.03),
    0 18px 34px rgba(7, 11, 28, 0.16);
}

.revenue-workspace-grid,
.revenue-report-grid {
  display: grid;
  gap: 16px;
  align-items: start;
  width: 100%;
  min-width: 0;
}

.revenue-ops-grid {
  grid-template-columns: minmax(320px, 0.8fr) minmax(0, 1.2fr);
}

.revenue-pipeline-shell {
  display: grid;
  grid-template-columns: minmax(300px, 0.72fr) minmax(0, 1.28fr);
  gap: 16px;
  align-items: start;
  width: 100%;
  min-width: 0;
}

.revenue-priority-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.28fr) minmax(260px, 0.88fr) minmax(260px, 0.88fr);
  gap: 14px;
  align-items: start;
}

.revenue-glance-strip,
.revenue-insight-grid {
  display: grid;
  gap: 12px;
  align-items: start;
}

.revenue-glance-strip {
  grid-template-columns: repeat(auto-fit, minmax(176px, 1fr));
}

.revenue-insight-grid {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.revenue-workspace-grid {
  grid-template-columns: minmax(340px, 0.82fr) minmax(0, 1.18fr);
}

.revenue-report-grid {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.revenue-sales-grid {
  grid-template-columns: 1fr;
}

.revenue-pipeline-grid {
  grid-template-columns: 1fr;
}

.revenue-operations-grid {
  grid-template-columns: 1fr 1fr;
}

.revenue-inline-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.revenue-inline-form {
  gap: 12px;
}

.revenue-inline-note {
  margin-top: 12px;
  color: rgba(214, 223, 247, 0.76);
  font-size: 0.82rem;
}

.revenue-compact-block {
  display: grid;
  gap: 12px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(176, 203, 255, 0.1);
  background: rgba(255, 255, 255, 0.03);
}

.revenue-toggle-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.revenue-toggle-card {
  min-height: 108px;
  align-content: start;
  gap: 8px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(176, 203, 255, 0.12);
  background:
    radial-gradient(circle at top right, rgba(83, 205, 190, 0.12), transparent 35%),
    linear-gradient(180deg, rgba(27, 35, 69, 0.94), rgba(15, 21, 41, 0.98));
}

.revenue-toggle-card span {
  color: #ffffff;
  font: 700 0.88rem "Space Grotesk", sans-serif;
}

.revenue-toggle-card small {
  color: rgba(214, 223, 247, 0.72);
  line-height: 1.4;
}

.revenue-time-range {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.revenue-lead-list,
.revenue-timeline-list,
.revenue-ledger-list,
.revenue-chart-list {
  display: grid;
  gap: 10px;
}

.revenue-lead-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.revenue-lead-toolbar-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.revenue-lead-select {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: rgba(220, 228, 250, 0.82);
  font-size: 0.76rem;
  letter-spacing: 0.01em;
}

.revenue-lead-select input {
  margin: 0;
}

.revenue-lead-card {
  text-align: left;
  gap: 10px;
  padding: 12px;
  border-radius: 18px;
  border: 1px solid rgba(183, 209, 255, 0.12);
  background:
    linear-gradient(180deg, rgba(38, 47, 88, 0.95), rgba(20, 26, 50, 0.98));
  cursor: pointer;
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease, filter 160ms ease;
}

.revenue-lead-card-top,
.revenue-lead-card-glance,
.revenue-board-card-head,
.revenue-board-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.revenue-lead-card-glance {
  flex-wrap: wrap;
}

.revenue-lead-card-note {
  margin: 0;
  color: rgba(223, 230, 248, 0.82);
  font-size: 0.82rem;
  line-height: 1.42;
}

.revenue-row-actions.compact {
  gap: 6px;
  flex-wrap: wrap;
}

.revenue-row-actions.compact .secondary-button {
  min-height: 30px;
  padding: 0 10px;
  font-size: 0.72rem;
}

.revenue-lead-mini-stats.compact {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.revenue-pipeline-board {
  display: grid;
  grid-template-columns: repeat(5, minmax(220px, 1fr));
  gap: 14px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.revenue-board-column {
  display: grid;
  gap: 12px;
  min-width: 220px;
}

.revenue-board-column-head {
  display: grid;
  gap: 6px;
  padding: 12px 14px;
  border-radius: 18px;
  border: 1px solid rgba(168, 191, 255, 0.12);
  background: linear-gradient(180deg, rgba(31, 40, 73, 0.96), rgba(18, 24, 45, 0.98));
}

.revenue-board-column-head div {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
}

.revenue-board-column-topline .pill {
  flex-shrink: 0;
}

.revenue-board-column-metrics {
  display: grid;
  gap: 4px;
}

.revenue-board-column-health {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  padding-top: 4px;
  border-top: 1px solid rgba(171, 194, 255, 0.12);
}

.revenue-board-column-head span,
.revenue-board-column-head small {
  color: rgba(209, 220, 247, 0.72);
}

.revenue-board-column-head strong {
  color: #ffffff;
  font: 700 1.22rem "Space Grotesk", sans-serif;
  letter-spacing: -0.03em;
}

.revenue-board-dropzone {
  display: grid;
  gap: 10px;
  min-height: 220px;
  padding: 10px;
  border-radius: 18px;
  border: 1px dashed rgba(154, 183, 255, 0.16);
  background: linear-gradient(180deg, rgba(17, 23, 43, 0.96), rgba(10, 15, 29, 0.98));
}

.revenue-board-dropzone.is-target {
  border-color: rgba(118, 210, 255, 0.42);
  box-shadow:
    inset 0 0 0 1px rgba(119, 217, 255, 0.18),
    0 0 0 1px rgba(119, 217, 255, 0.12);
  background:
    radial-gradient(circle at top left, rgba(91, 211, 255, 0.12), transparent 34%),
    linear-gradient(180deg, rgba(20, 30, 58, 0.98), rgba(10, 16, 31, 1));
}

.revenue-board-card {
  border-radius: 18px;
  border: 1px solid rgba(185, 206, 255, 0.12);
  background:
    linear-gradient(180deg, rgba(33, 44, 83, 0.95), rgba(18, 25, 47, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 14px 22px rgba(7, 11, 24, 0.14);
}

.revenue-board-card-head {
  align-items: flex-start;
}

.revenue-board-card-title {
  display: grid;
  gap: 4px;
}

.revenue-board-card-head-meta {
  display: grid;
  justify-items: end;
  gap: 8px;
}

.revenue-board-card-affordance {
  color: rgba(167, 201, 255, 0.78);
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.revenue-board-card-grip {
  color: rgba(198, 214, 249, 0.72);
  font: 700 1rem/1 "IBM Plex Mono", monospace;
  letter-spacing: 0.12em;
}

.revenue-board-card p {
  margin: 0;
  color: rgba(223, 230, 248, 0.82);
  line-height: 1.45;
}

.revenue-board-empty {
  padding: 18px 14px;
  border-radius: 16px;
  border: 1px dashed rgba(186, 204, 248, 0.14);
  color: rgba(204, 216, 244, 0.72);
  line-height: 1.5;
  text-align: left;
}

.revenue-board-card {
  display: grid;
  gap: 10px;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid rgba(170, 197, 255, 0.12);
  background: linear-gradient(180deg, rgba(37, 48, 91, 0.96), rgba(21, 28, 52, 0.98));
  cursor: grab;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease, filter 160ms ease, opacity 160ms ease;
}

.revenue-board-card p,
.revenue-board-empty {
  margin: 0;
  color: rgba(216, 225, 247, 0.82);
  font-size: 0.82rem;
  line-height: 1.42;
}

.revenue-board-empty {
  display: grid;
  place-items: center;
  min-height: 140px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.025);
}

.revenue-board-card-foot {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  color: rgba(194, 207, 241, 0.7);
  font-size: 0.72rem;
}

.revenue-board-card:hover {
  transform: translateY(-2px);
  border-color: rgba(151, 206, 255, 0.26);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 18px 28px rgba(7, 11, 24, 0.18);
}

.revenue-board-card:focus-visible {
  outline: none;
  border-color: rgba(119, 209, 255, 0.38);
  box-shadow:
    inset 0 0 0 1px rgba(117, 206, 255, 0.16),
    0 0 0 3px rgba(79, 181, 255, 0.14),
    0 18px 28px rgba(7, 11, 24, 0.18);
}

.revenue-board-card.active {
  border-color: rgba(119, 209, 255, 0.34);
  background:
    radial-gradient(circle at top right, rgba(84, 230, 255, 0.12), transparent 36%),
    linear-gradient(180deg, rgba(39, 54, 100, 0.98), rgba(18, 27, 53, 1));
  box-shadow:
    inset 0 0 0 1px rgba(117, 206, 255, 0.14),
    0 20px 34px rgba(7, 11, 24, 0.22);
}

.revenue-board-card.dragging {
  opacity: 0.5;
  transform: rotate(1.2deg) scale(0.98);
  cursor: grabbing;
}

.revenue-modal-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.revenue-lead-card:hover {
  border-color: rgba(152, 194, 255, 0.3);
  transform: translateY(-1px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 16px 28px rgba(6, 10, 24, 0.18);
  filter: brightness(1.03);
}

.revenue-action-item,
.revenue-stalled-item,
.revenue-campaign-card,
.revenue-timeline-entry,
.revenue-ledger-entry {
  transition: transform 150ms ease, border-color 150ms ease, box-shadow 150ms ease, filter 150ms ease;
}

.revenue-action-item:hover,
.revenue-stalled-item:hover,
.revenue-campaign-card:hover,
.revenue-timeline-entry:hover,
.revenue-ledger-entry:hover {
  border-color: rgba(161, 198, 255, 0.28);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 14px 24px rgba(8, 12, 28, 0.16);
  filter: brightness(1.03);
}

.revenue-lead-mini-stats {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.revenue-lead-row-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: rgba(214, 223, 247, 0.74);
  font-size: 0.8rem;
}

.revenue-row-actions,
.revenue-quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.revenue-row-actions .secondary-button,
.revenue-quick-actions .secondary-button {
  min-height: 34px;
  padding: 0 12px;
  font-size: 0.78rem;
}

.revenue-workspace-shell .primary-button,
.revenue-workspace-shell .secondary-button {
  min-height: 40px;
  border-radius: 12px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 12px 22px rgba(8, 12, 28, 0.16);
}

.revenue-workspace-shell .secondary-button {
  background:
    linear-gradient(180deg, rgba(35, 42, 76, 0.92), rgba(19, 25, 47, 0.98));
  border: 1px solid rgba(152, 179, 255, 0.18);
}

.revenue-workspace-shell .primary-button:hover,
.revenue-workspace-shell .secondary-button:hover,
.revenue-workspace-shell select:hover,
.revenue-workspace-shell input:hover,
.revenue-workspace-shell textarea:hover {
  border-color: rgba(184, 208, 255, 0.34);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 16px 28px rgba(8, 12, 28, 0.2);
}

.revenue-workspace-shell button,
.revenue-workspace-shell select,
.revenue-workspace-shell input,
.revenue-workspace-shell textarea,
.revenue-workspace-shell [data-revenue-lead-id],
.revenue-workspace-shell [data-revenue-inline-action],
.revenue-workspace-shell [data-revenue-quick-action],
.revenue-workspace-shell [data-revenue-campaign-launch] {
  cursor: pointer;
}

.revenue-workspace-shell input,
.revenue-workspace-shell textarea {
  cursor: text;
}

.revenue-workspace-shell .revenue-glance-card,
.revenue-workspace-shell .revenue-chart-card,
.revenue-workspace-shell .revenue-fit-card,
.revenue-workspace-shell .revenue-candidate-entry,
.revenue-workspace-shell .revenue-signal-item {
  cursor: default;
}

.revenue-workspace-shell input,
.revenue-workspace-shell select,
.revenue-workspace-shell textarea {
  border: 1px solid rgba(157, 182, 241, 0.16);
  background:
    linear-gradient(180deg, rgba(18, 25, 47, 0.96), rgba(12, 18, 36, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.03),
    0 10px 18px rgba(5, 9, 20, 0.12);
}

.revenue-workspace-shell input:focus,
.revenue-workspace-shell select:focus,
.revenue-workspace-shell textarea:focus {
  outline: none;
  border-color: rgba(132, 189, 255, 0.52);
  box-shadow:
    0 0 0 3px rgba(95, 151, 255, 0.14),
    0 12px 24px rgba(9, 14, 30, 0.18);
}

.revenue-workspace-shell .primary-button {
  background:
    linear-gradient(135deg, rgba(84, 155, 255, 0.98), rgba(122, 92, 255, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    0 18px 28px rgba(69, 95, 255, 0.28);
}

.revenue-fit-card,
.revenue-candidate-entry {
  display: grid;
  gap: 10px;
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid rgba(176, 203, 255, 0.12);
  background:
    radial-gradient(circle at top right, rgba(87, 215, 190, 0.12), transparent 36%),
    radial-gradient(circle at bottom left, rgba(125, 110, 255, 0.16), transparent 42%),
    linear-gradient(180deg, rgba(28, 37, 72, 0.95), rgba(17, 23, 45, 0.98));
}

.revenue-fit-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.revenue-fit-head span {
  color: rgba(208, 219, 247, 0.72);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.revenue-fit-head strong {
  color: #ffffff;
  font: 700 1.12rem "Space Grotesk", sans-serif;
}

.revenue-fit-card .helper-text,
.revenue-candidate-entry p {
  margin: 0;
  color: rgba(214, 223, 247, 0.78);
  line-height: 1.5;
}

.revenue-action-item,
.revenue-stalled-item {
  width: 100%;
  text-align: left;
}

.revenue-summary-grid,
.revenue-report-cards {
  display: grid;
  gap: 10px;
}

.revenue-summary-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.revenue-report-cards {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.revenue-glance-card {
  display: grid;
  gap: 6px;
  min-height: 82px;
  padding: 12px 14px;
  border-radius: 18px;
  border: 1px solid rgba(183, 209, 255, 0.12);
  background:
    radial-gradient(circle at top right, rgba(73, 199, 202, 0.16), transparent 34%),
    radial-gradient(circle at bottom left, rgba(160, 104, 255, 0.18), transparent 40%),
    linear-gradient(180deg, rgba(32, 40, 76, 0.96), rgba(17, 24, 49, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 18px 34px rgba(7, 12, 28, 0.18);
  opacity: 0.92;
}

.revenue-glance-card span,
.revenue-report-card span {
  color: rgba(208, 219, 247, 0.76);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.revenue-glance-card strong {
  color: #ffffff;
  font: 700 1.18rem "Space Grotesk", sans-serif;
}

.revenue-glance-card small {
  color: rgba(214, 223, 247, 0.72);
  font-size: 0.76rem;
}

.revenue-glance-strip .revenue-glance-card:first-child,
.revenue-glance-strip .revenue-glance-card:nth-child(2) {
  border-color: rgba(128, 190, 255, 0.22);
  background:
    radial-gradient(circle at top right, rgba(88, 203, 210, 0.2), transparent 34%),
    radial-gradient(circle at bottom left, rgba(160, 104, 255, 0.22), transparent 40%),
    linear-gradient(180deg, rgba(36, 47, 88, 0.98), rgba(18, 25, 52, 1));
  opacity: 1;
}

.revenue-report-card small {
  display: block;
}

.revenue-chart-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
  align-items: start;
}

.revenue-operations-command {
  display: grid;
}

.revenue-chart-card,
.revenue-timeline-entry,
.revenue-ledger-entry,
.revenue-campaign-card {
  padding: 13px 15px;
  min-width: 0;
  border-radius: 18px;
  border: 1px solid rgba(176, 203, 255, 0.12);
  background:
    radial-gradient(circle at top right, rgba(137, 97, 255, 0.12), transparent 34%),
    linear-gradient(180deg, rgba(33, 40, 76, 0.94), rgba(18, 24, 48, 0.98));
}

.revenue-chart-card {
  opacity: 0.88;
}

.revenue-timeline-entry,
.revenue-ledger-entry,
.revenue-campaign-card {
  opacity: 0.96;
}

.revenue-panel {
  min-width: 0;
  overflow: hidden;
}

.revenue-workspace-shell {
  border: 1px solid rgba(117, 146, 230, 0.16);
  border-radius: 34px;
  background:
    radial-gradient(circle at top left, rgba(132, 93, 255, 0.12), transparent 24%),
    radial-gradient(circle at top right, rgba(84, 230, 255, 0.08), transparent 26%),
    linear-gradient(180deg, rgba(16, 23, 50, 0.96), rgba(7, 13, 30, 0.99));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 28px 64px rgba(4, 9, 22, 0.3);
}

.revenue-shell-head {
  padding: 20px 18px 14px;
  border-radius: 28px;
  border: 1px solid rgba(139, 170, 248, 0.12);
  background:
    linear-gradient(135deg, rgba(35, 45, 88, 0.92), rgba(17, 27, 56, 0.96)),
    radial-gradient(circle at top right, rgba(84, 230, 255, 0.08), transparent 24%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 16px 30px rgba(8, 12, 28, 0.18);
}

.revenue-shell-head h4 {
  font-size: clamp(1.75rem, 2.2vw, 2.3rem);
  letter-spacing: -0.04em;
}

.revenue-shell-alerts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
}

.revenue-alert-card {
  min-height: 104px;
  align-content: start;
  border-radius: 20px;
}

.revenue-module-tabbar {
  margin-top: 14px;
  padding: 10px;
  border-radius: 28px;
  border: 1px solid rgba(132, 159, 233, 0.1);
  background:
    linear-gradient(180deg, rgba(11, 17, 36, 0.96), rgba(15, 22, 44, 0.92));
}

.revenue-workspace-grid {
  grid-template-columns: minmax(390px, 0.92fr) minmax(0, 1.08fr);
  gap: 18px;
}

.revenue-panel {
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(22, 31, 62, 0.94), rgba(11, 18, 38, 0.97)),
    rgba(12, 20, 40, 0.94);
  overflow: hidden;
}

.revenue-lead-list,
.revenue-timeline-list,
.revenue-ledger-list {
  max-height: 860px;
  overflow-y: auto;
  overflow-x: hidden;
  padding-right: 4px;
}

.revenue-lead-card {
  min-width: 0;
  gap: 12px;
  padding: 15px 15px 14px;
  border-radius: 22px;
  border-color: rgba(183, 209, 255, 0.14);
  background:
    radial-gradient(circle at top right, rgba(84, 230, 255, 0.08), transparent 28%),
    linear-gradient(180deg, rgba(40, 50, 95, 0.96), rgba(19, 26, 52, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 14px 28px rgba(8, 11, 27, 0.14);
}

.revenue-lead-card > *,
.revenue-lead-card .content-item-head,
.revenue-lead-card .content-item-head > div,
.revenue-board-card > * {
  min-width: 0;
}

.revenue-lead-card.active {
  border-color: rgba(132, 203, 255, 0.34);
  background:
    radial-gradient(circle at top right, rgba(84, 230, 255, 0.14), transparent 34%),
    radial-gradient(circle at bottom left, rgba(145, 103, 255, 0.14), transparent 32%),
    linear-gradient(180deg, rgba(53, 67, 122, 0.98), rgba(24, 33, 66, 0.99));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 20px 40px rgba(7, 11, 26, 0.22);
}

.revenue-lead-card-top {
  align-items: flex-start;
}

.revenue-lead-card[data-stage-tone="new_deal"] {
  background:
    radial-gradient(circle at top right, rgba(84, 230, 255, 0.1), transparent 28%),
    linear-gradient(180deg, rgba(40, 50, 95, 0.96), rgba(19, 26, 52, 0.98));
}

.revenue-lead-card[data-stage-tone="scoping"] {
  background:
    radial-gradient(circle at top right, rgba(100, 226, 191, 0.14), transparent 30%),
    linear-gradient(180deg, rgba(31, 57, 78, 0.96), rgba(16, 30, 42, 0.98));
}

.revenue-lead-card[data-stage-tone="sow"] {
  background:
    radial-gradient(circle at top right, rgba(255, 189, 94, 0.14), transparent 30%),
    linear-gradient(180deg, rgba(72, 52, 35, 0.96), rgba(38, 27, 19, 0.98));
}

.revenue-lead-card[data-stage-tone="closed_won"] {
  background:
    radial-gradient(circle at top right, rgba(117, 238, 186, 0.14), transparent 30%),
    linear-gradient(180deg, rgba(25, 60, 57, 0.96), rgba(13, 31, 30, 0.98));
}

.revenue-lead-card[data-stage-tone="closed_lost"] {
  background:
    radial-gradient(circle at top right, rgba(255, 122, 139, 0.12), transparent 30%),
    linear-gradient(180deg, rgba(66, 35, 50, 0.96), rgba(31, 18, 27, 0.98));
}

.revenue-lead-card .content-item-head strong,
.revenue-board-card strong {
  display: block;
  overflow-wrap: anywhere;
}

.revenue-lead-card .mapping-meta,
.revenue-board-card .mapping-meta,
.revenue-board-card p {
  overflow-wrap: anywhere;
  word-break: break-word;
}

.revenue-lead-card-glance {
  align-items: flex-start;
}

.revenue-lead-card-glance .pill {
  max-width: 100%;
}

.revenue-lead-mini-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.revenue-lead-mini-stats > div {
  min-width: 0;
  padding: 10px 12px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.05);
}

.revenue-lead-mini-stats strong {
  overflow-wrap: anywhere;
}

.revenue-fit-card,
.revenue-chart-card,
.revenue-timeline-entry,
.revenue-ledger-entry,
.revenue-campaign-card {
  border-radius: 22px;
  border-color: rgba(180, 203, 255, 0.13);
}

.revenue-fit-card {
  padding: 16px 18px;
  background:
    radial-gradient(circle at top right, rgba(84, 230, 255, 0.12), transparent 34%),
    linear-gradient(180deg, rgba(28, 39, 78, 0.96), rgba(15, 22, 44, 0.98));
}

.revenue-lead-detail-panel {
  background:
    radial-gradient(circle at top right, rgba(255, 181, 94, 0.09), transparent 34%),
    radial-gradient(circle at bottom left, rgba(80, 222, 255, 0.1), transparent 42%),
    linear-gradient(180deg, rgba(32, 38, 73, 0.98), rgba(14, 19, 39, 1));
  border-color: rgba(255, 194, 126, 0.14);
  box-shadow:
    inset 0 1px 0 rgba(255, 244, 213, 0.05),
    0 22px 46px rgba(7, 11, 26, 0.24);
}

.revenue-fit-card-primary {
  background:
    radial-gradient(circle at top right, rgba(80, 224, 255, 0.16), transparent 34%),
    linear-gradient(180deg, rgba(30, 49, 87, 0.98), rgba(15, 26, 48, 1));
}

.revenue-fit-card-recommendation {
  background:
    radial-gradient(circle at top right, rgba(255, 186, 93, 0.18), transparent 34%),
    linear-gradient(180deg, rgba(74, 50, 35, 0.94), rgba(33, 23, 20, 0.98));
}

.revenue-fit-head strong {
  font-size: 1.24rem;
  letter-spacing: -0.03em;
}

.revenue-quick-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.revenue-quick-actions .secondary-button {
  min-height: 42px;
  border-radius: 16px;
  justify-content: center;
  font-weight: 700;
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 12px 20px rgba(8, 11, 27, 0.16);
}

.revenue-quick-actions .secondary-button[data-action-tone="email"] {
  background: linear-gradient(180deg, rgba(63, 119, 255, 0.96), rgba(39, 71, 176, 0.98));
  color: #ffffff;
}

.revenue-quick-actions .secondary-button[data-action-tone="meeting"] {
  background: linear-gradient(180deg, rgba(76, 179, 158, 0.96), rgba(34, 102, 93, 0.98));
  color: #f4fffd;
}

.revenue-quick-actions .secondary-button[data-action-tone="note"] {
  background: linear-gradient(180deg, rgba(93, 120, 196, 0.96), rgba(48, 65, 123, 0.98));
  color: #ffffff;
}

.revenue-quick-actions .secondary-button[data-action-tone="won"] {
  background: linear-gradient(180deg, rgba(73, 189, 120, 0.96), rgba(33, 108, 67, 0.98));
  color: #f7fff8;
}

.revenue-quick-actions .secondary-button[data-action-tone="lost"] {
  background: linear-gradient(180deg, rgba(177, 114, 67, 0.96), rgba(112, 61, 31, 0.98));
  color: #fff8f3;
}

.revenue-quick-actions .secondary-button[data-action-tone="delete"] {
  background: linear-gradient(180deg, rgba(173, 73, 94, 0.96), rgba(105, 34, 51, 0.98));
  color: #fff5f7;
}

.revenue-row-actions.compact {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.revenue-row-actions.compact .secondary-button {
  min-width: 0;
}

.revenue-row-actions.compact .secondary-button[data-inline-tone="email"] {
  background: rgba(59, 94, 204, 0.22);
  border-color: rgba(108, 151, 255, 0.22);
}

.revenue-row-actions.compact .secondary-button[data-inline-tone="meeting"] {
  background: rgba(45, 150, 126, 0.2);
  border-color: rgba(106, 231, 196, 0.18);
}

.revenue-row-actions.compact .secondary-button[data-inline-tone="delete"] {
  background: rgba(132, 53, 69, 0.2);
  border-color: rgba(255, 132, 156, 0.18);
}

.revenue-summary-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.revenue-summary-grid .detail-kpi {
  min-height: 92px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(180, 203, 255, 0.12);
  background:
    linear-gradient(180deg, rgba(19, 27, 54, 0.92), rgba(11, 17, 35, 0.96));
}

.revenue-summary-grid .detail-kpi strong {
  font-size: 1rem;
  line-height: 1.3;
}

.revenue-journey-card {
  display: grid;
  gap: 12px;
  padding: 16px;
  border-radius: 22px;
  border: 1px solid rgba(180, 203, 255, 0.12);
  background:
    radial-gradient(circle at top right, rgba(85, 206, 255, 0.1), transparent 32%),
    linear-gradient(180deg, rgba(22, 31, 61, 0.94), rgba(11, 16, 34, 0.98));
}

.revenue-journey-card-detail {
  background:
    radial-gradient(circle at top right, rgba(255, 205, 120, 0.1), transparent 32%),
    radial-gradient(circle at bottom left, rgba(89, 208, 255, 0.08), transparent 38%),
    linear-gradient(180deg, rgba(39, 37, 63, 0.94), rgba(19, 18, 36, 0.98));
}

.revenue-journey-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(116px, 1fr));
  gap: 10px;
}

.revenue-journey-phase,
.revenue-journey-event {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(176, 198, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
}

.revenue-journey-phase span,
.revenue-journey-event span {
  color: rgba(188, 202, 236, 0.76);
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.revenue-journey-phase strong,
.revenue-journey-event strong {
  color: #ffffff;
  font-size: 0.92rem;
  line-height: 1.28;
}

.revenue-journey-phase[data-state="complete"] {
  background:
    radial-gradient(circle at top left, rgba(84, 230, 166, 0.12), transparent 32%),
    linear-gradient(180deg, rgba(30, 57, 66, 0.94), rgba(14, 27, 35, 0.98));
  box-shadow: inset 0 0 0 1px rgba(117, 238, 186, 0.16);
}

.revenue-journey-phase[data-state="current"] {
  background:
    radial-gradient(circle at top left, rgba(96, 189, 255, 0.14), transparent 32%),
    linear-gradient(180deg, rgba(31, 50, 79, 0.94), rgba(14, 24, 42, 0.98));
  box-shadow: inset 0 0 0 1px rgba(123, 198, 255, 0.16);
}

.revenue-journey-timeline {
  display: grid;
  gap: 10px;
}

.revenue-journey-event p {
  margin: 0;
  color: rgba(211, 220, 242, 0.78);
  line-height: 1.5;
}

.revenue-inline-note {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
}

.revenue-pipeline-shell {
  grid-template-columns: minmax(280px, 0.56fr) minmax(0, 1.44fr);
  gap: 18px;
}

.revenue-pipeline-board {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(255px, 1fr);
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 8px;
  align-items: start;
  scroll-snap-type: x proximity;
}

.revenue-board-column {
  display: grid;
  gap: 12px;
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(28, 38, 75, 0.9), rgba(16, 22, 43, 0.96));
  min-width: 255px;
  padding: 10px;
  scroll-snap-align: start;
}

.revenue-board-column[data-revenue-board-stage="new_deal"] {
  background:
    radial-gradient(circle at top right, rgba(72, 206, 255, 0.12), transparent 34%),
    linear-gradient(180deg, rgba(24, 47, 75, 0.94), rgba(13, 25, 39, 0.98));
}

.revenue-board-column[data-revenue-board-stage="scoping"] {
  background:
    radial-gradient(circle at top right, rgba(99, 231, 190, 0.14), transparent 34%),
    linear-gradient(180deg, rgba(22, 58, 68, 0.94), rgba(11, 30, 35, 0.98));
}

.revenue-board-column[data-revenue-board-stage="sow"] {
  background:
    radial-gradient(circle at top right, rgba(255, 189, 94, 0.16), transparent 34%),
    linear-gradient(180deg, rgba(74, 50, 35, 0.94), rgba(33, 23, 20, 0.98));
}

.revenue-board-column[data-revenue-board-stage="closed_won"] {
  background:
    radial-gradient(circle at top right, rgba(116, 238, 185, 0.16), transparent 34%),
    linear-gradient(180deg, rgba(24, 63, 58, 0.94), rgba(11, 31, 29, 0.98));
}

.revenue-board-column[data-revenue-board-stage="closed_lost"] {
  background:
    radial-gradient(circle at top right, rgba(255, 130, 145, 0.14), transparent 34%),
    linear-gradient(180deg, rgba(68, 35, 49, 0.94), rgba(28, 18, 27, 0.98));
}

.revenue-pipeline-drawer {
  display: grid;
  gap: 14px;
  margin-top: 16px;
  padding: 18px;
  border-radius: 24px;
  border: 1px solid rgba(180, 203, 255, 0.14);
  background:
    radial-gradient(circle at top right, rgba(255, 187, 95, 0.12), transparent 32%),
    radial-gradient(circle at bottom left, rgba(88, 214, 255, 0.1), transparent 36%),
    linear-gradient(180deg, rgba(29, 36, 70, 0.97), rgba(14, 20, 40, 1));
}

.revenue-pipeline-drawer.is-empty {
  background:
    linear-gradient(180deg, rgba(23, 30, 57, 0.95), rgba(12, 17, 33, 0.98));
}

.revenue-pipeline-drawer-glance {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.revenue-pipeline-drawer-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.9fr);
  gap: 12px;
}

.revenue-pipeline-drawer-copy {
  display: grid;
  gap: 8px;
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(180, 203, 255, 0.09);
}

.revenue-pipeline-drawer-copy-secondary {
  background:
    radial-gradient(circle at top right, rgba(84, 230, 255, 0.08), transparent 30%),
    rgba(255, 255, 255, 0.04);
}

.revenue-pipeline-drawer-copy strong {
  color: #ffffff;
  font-size: 1rem;
}

.revenue-pipeline-drawer-copy p {
  margin: 0;
  color: rgba(214, 223, 247, 0.82);
  line-height: 1.55;
}

.revenue-pipeline-feedback {
  display: grid;
  gap: 6px;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(185, 206, 255, 0.16);
  background: rgba(255, 255, 255, 0.05);
}

.revenue-pipeline-feedback strong {
  color: #ffffff;
}

.revenue-pipeline-feedback p {
  margin: 0;
  color: rgba(216, 225, 247, 0.82);
  line-height: 1.45;
}

.revenue-pipeline-feedback[data-tone="live"] {
  background:
    radial-gradient(circle at top right, rgba(92, 238, 187, 0.16), transparent 34%),
    rgba(20, 58, 53, 0.72);
  border-color: rgba(119, 241, 190, 0.28);
}

.revenue-pipeline-feedback[data-tone="warning"] {
  background:
    radial-gradient(circle at top right, rgba(255, 188, 88, 0.16), transparent 34%),
    rgba(68, 44, 26, 0.72);
  border-color: rgba(255, 198, 122, 0.28);
}

.revenue-pipeline-drawer-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.revenue-pipeline-stage-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.revenue-pipeline-stage-actions .secondary-button {
  min-height: 46px;
  justify-content: center;
  font-weight: 700;
}

.revenue-pipeline-stage-actions .secondary-button[data-pipeline-action-tone="email"] {
  background: linear-gradient(180deg, rgba(63, 119, 255, 0.96), rgba(39, 71, 176, 0.98));
  color: #ffffff;
}

.revenue-pipeline-stage-actions .secondary-button[data-pipeline-action-tone="meeting"] {
  background: linear-gradient(180deg, rgba(76, 179, 158, 0.96), rgba(34, 102, 93, 0.98));
  color: #f4fffd;
}

.revenue-pipeline-stage-actions .secondary-button[data-pipeline-action-tone="proposal"] {
  background: linear-gradient(180deg, rgba(196, 132, 68, 0.96), rgba(117, 71, 35, 0.98));
  color: #fff8f1;
}

.revenue-pipeline-stage-actions .secondary-button[data-pipeline-action-tone="payment"] {
  background: linear-gradient(180deg, rgba(128, 115, 255, 0.96), rgba(72, 55, 177, 0.98));
  color: #fbf9ff;
}

.revenue-pipeline-stage-actions .secondary-button[data-pipeline-action-tone="won"] {
  background: linear-gradient(180deg, rgba(73, 189, 120, 0.96), rgba(33, 108, 67, 0.98));
  color: #f7fff8;
}

.revenue-pipeline-stage-actions .secondary-button[data-pipeline-action-tone="lost"] {
  background: linear-gradient(180deg, rgba(173, 73, 94, 0.96), rgba(105, 34, 51, 0.98));
  color: #fff5f7;
}

.revenue-report-grid {
  gap: 14px;
}

#revenueReportsGlanceStrip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 6px;
}

.revenue-glance-card {
  min-height: 92px;
  padding: 14px 16px;
  border-radius: 20px;
}

.revenue-glance-card strong {
  font-size: 1.5rem;
  letter-spacing: -0.04em;
}

.revenue-chart-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.revenue-chart-card {
  min-height: 210px;
  padding: 16px 16px 14px;
  background:
    radial-gradient(circle at top right, rgba(128, 105, 255, 0.1), transparent 30%),
    linear-gradient(180deg, rgba(26, 35, 70, 0.94), rgba(13, 19, 39, 0.98));
}

.revenue-report-card {
  min-height: 112px;
  border-radius: 20px;
  background:
    radial-gradient(circle at top right, rgba(84, 230, 255, 0.12), transparent 30%),
    linear-gradient(180deg, rgba(35, 47, 86, 0.95), rgba(17, 24, 46, 0.99));
}

.revenue-report-card strong {
  font-size: 1.42rem;
  letter-spacing: -0.04em;
}

.revenue-chart-card > strong {
  display: block;
  margin-bottom: 12px;
  font: 700 0.98rem "Space Grotesk", sans-serif;
}

.revenue-signal-list {
  display: grid;
  gap: 10px;
}

.revenue-signal-item {
  display: grid;
  gap: 8px;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(183, 209, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
}

.revenue-signal-item[data-tone="positive"] {
  background: linear-gradient(180deg, rgba(33, 76, 74, 0.34), rgba(17, 33, 40, 0.66));
}

.revenue-signal-item[data-tone="warning"] {
  background: linear-gradient(180deg, rgba(88, 63, 27, 0.34), rgba(39, 25, 16, 0.66));
}

.revenue-signal-item[data-tone="accent"] {
  background: linear-gradient(180deg, rgba(55, 41, 92, 0.36), rgba(22, 23, 46, 0.66));
}

.revenue-signal-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.revenue-signal-head strong {
  color: #ffffff;
  font-size: 0.92rem;
}

.revenue-signal-head span {
  color: rgba(180, 236, 224, 0.92);
  font: 700 0.78rem "Space Grotesk", sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.revenue-signal-item p {
  margin: 0;
  color: rgba(214, 223, 247, 0.78);
  font-size: 0.82rem;
  line-height: 1.45;
}

.revenue-campaign-list,
.revenue-candidate-list,
.revenue-touch-list,
.revenue-event-list,
.revenue-policy-list {
  display: grid;
  gap: 10px;
}

.revenue-sequence-cards {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.revenue-campaign-card {
  gap: 14px;
}

.revenue-campaign-card .hero-badges {
  align-items: center;
}

.revenue-campaign-card .secondary-button {
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
}

.revenue-policy-list {
  grid-template-columns: repeat(auto-fit, minmax(130px, max-content));
  gap: 8px;
}

.revenue-touch-list {
  grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
}

.revenue-touch-chip {
  display: grid;
  gap: 4px;
  min-height: 78px;
  padding: 10px 12px;
  border-radius: 16px;
  border: 1px solid rgba(173, 204, 255, 0.12);
  background:
    linear-gradient(180deg, rgba(43, 56, 101, 0.78), rgba(19, 25, 48, 0.92));
}

.revenue-touch-chip span,
.revenue-touch-chip small {
  color: rgba(208, 219, 247, 0.72);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.revenue-touch-chip strong {
  color: #ffffff;
  font: 700 0.88rem "Space Grotesk", sans-serif;
}

.revenue-event-entry {
  display: grid;
  gap: 8px;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(176, 203, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
}

.revenue-event-entry p {
  margin: 0;
  color: rgba(214, 223, 247, 0.78);
  line-height: 1.45;
}

.revenue-chart-row {
  display: grid;
  gap: 8px;
}

.revenue-chart-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  color: rgba(214, 223, 247, 0.88);
  font-size: 0.84rem;
}

.revenue-chart-bar {
  height: 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.revenue-chart-bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(83, 205, 190, 0.96), rgba(119, 143, 255, 0.96));
  box-shadow: 0 0 18px rgba(89, 176, 255, 0.22);
}

#revenueSidebarCard .summary-row strong,
.revenue-summary-grid .detail-kpi strong,
.revenue-timeline-entry strong,
.revenue-ledger-entry strong {
  color: #ffffff;
}

@media (max-width: 1240px) {
  .module-operations-shell {
    grid-template-columns: 1fr;
  }

  .revenue-priority-grid,
  .revenue-glance-strip,
  .revenue-shell-alerts,
  .revenue-toggle-grid,
  .revenue-pipeline-shell,
  .revenue-ops-grid,
  .revenue-workspace-grid,
  .revenue-report-grid,
  .revenue-pipeline-grid,
  .revenue-operations-grid,
  .revenue-insight-grid,
  .revenue-chart-grid,
  .revenue-summary-grid,
  .revenue-report-cards {
    grid-template-columns: 1fr 1fr;
  }

  .revenue-pipeline-board {
    grid-auto-columns: minmax(240px, 1fr);
  }

  .revenue-pipeline-drawer-glance,
  .revenue-pipeline-drawer-body,
  .revenue-pipeline-stage-actions {
    grid-template-columns: 1fr 1fr;
  }

  .revenue-quick-actions,
  #revenueReportsGlanceStrip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .revenue-shell-head {
    grid-template-columns: 1fr;
  }

  .workspace-brand-line {
    gap: 6px;
  }

  .workspace-brand-tagline {
    font-size: 0.68rem;
  }

  .output-review-actions-inline,
  .agent-output-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .revenue-priority-grid,
  .revenue-glance-strip,
  .revenue-shell-alerts,
  .revenue-inline-grid,
  .revenue-toggle-grid,
  .revenue-pipeline-shell,
  .revenue-ops-grid,
  .revenue-workspace-grid,
  .revenue-report-grid,
  .revenue-pipeline-grid,
  .revenue-operations-grid,
  .revenue-insight-grid,
  .revenue-chart-grid,
  .revenue-summary-grid,
  .revenue-report-cards {
    grid-template-columns: 1fr;
  }

  .revenue-lead-toolbar,
  .revenue-modal-grid {
    grid-template-columns: 1fr;
  }

  .revenue-lead-toolbar {
    display: grid;
    justify-content: stretch;
  }

  .revenue-pipeline-board {
    grid-auto-columns: minmax(260px, 1fr);
  }

  .revenue-pipeline-drawer-glance,
  .revenue-pipeline-drawer-body,
  .revenue-pipeline-stage-actions {
    grid-template-columns: 1fr;
  }

  .revenue-quick-actions,
  #revenueReportsGlanceStrip {
    grid-template-columns: 1fr;
  }

  .revenue-row-actions.compact,
  .revenue-lead-mini-stats {
    grid-template-columns: 1fr;
  }
}

.profile-modal-card {
  width: min(640px, 100%);
}

.signup-funnel-modal-card {
  width: min(980px, calc(100vw - 36px));
  padding: 16px;
  border-radius: 34px;
  background:
    radial-gradient(circle at top left, rgba(71, 196, 255, 0.12), transparent 26%),
    radial-gradient(circle at top right, rgba(164, 108, 255, 0.14), transparent 32%),
    linear-gradient(180deg, rgba(16, 23, 47, 0.98), rgba(7, 11, 26, 0.99));
  border: 1px solid rgba(133, 165, 255, 0.16);
}

.signup-funnel-shell {
  display: grid;
  gap: 14px;
}

.signup-funnel-topbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 14px;
  align-items: center;
}

.signup-funnel-stepper {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.signup-funnel-step {
  min-height: 42px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1px solid rgba(135, 160, 233, 0.16);
  background: rgba(16, 23, 50, 0.82);
  color: rgba(216, 225, 248, 0.76);
  font: 700 0.88rem "Space Grotesk", sans-serif;
}

.signup-funnel-step.active {
  background: linear-gradient(135deg, #ffd08a, #ffbf66);
  color: #271814;
  border-color: rgba(255, 207, 139, 0.36);
  box-shadow: 0 12px 26px rgba(255, 185, 90, 0.18);
}

.signup-funnel-step.complete {
  color: rgba(255, 255, 255, 0.9);
  border-color: rgba(126, 219, 255, 0.22);
  background: rgba(37, 54, 100, 0.84);
}

.signup-funnel-close {
  width: 46px;
  height: 46px;
  border-radius: 50%;
}

.signup-funnel-card {
  display: grid;
  min-height: 0;
  padding: 22px;
  border-radius: 30px;
  border: 1px solid rgba(127, 153, 221, 0.16);
  background:
    radial-gradient(circle at top right, rgba(77, 115, 255, 0.08), transparent 28%),
    linear-gradient(180deg, rgba(22, 31, 62, 0.96), rgba(10, 15, 33, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 24px 48px rgba(4, 7, 18, 0.3);
}

.signup-funnel-panel {
  display: none;
  gap: 20px;
}

.signup-funnel-panel.active {
  display: grid;
}

.signup-funnel-header-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(260px, 0.9fr);
  gap: 18px;
  align-items: center;
}

.signup-funnel-copy {
  display: grid;
  gap: 8px;
}

.signup-funnel-copy h4 {
  margin: 0;
  color: #ffffff;
  font-size: clamp(2.4rem, 4.6vw, 3.6rem);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.signup-funnel-copy p:last-child {
  margin: 0;
  color: rgba(212, 223, 248, 0.82);
  font-size: 1rem;
  line-height: 1.5;
}

.signup-funnel-brand-panel {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 16px;
  align-items: center;
  justify-self: end;
  width: min(100%, 360px);
}

.signup-funnel-brand-mark {
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  border-radius: 22px;
  background:
    radial-gradient(circle at 30% 28%, rgba(81, 209, 255, 0.32), transparent 26%),
    linear-gradient(145deg, rgba(68, 143, 255, 0.92), rgba(137, 92, 255, 0.94));
  box-shadow: 0 18px 34px rgba(56, 76, 167, 0.24);
}

.signup-funnel-brand-mark img {
  width: 52px;
  height: 52px;
  display: block;
}

.signup-funnel-brand-copy {
  display: grid;
  gap: 4px;
}

.signup-funnel-brand-copy strong {
  font: 700 clamp(2rem, 3.6vw, 3rem) "Space Grotesk", sans-serif;
  letter-spacing: -0.05em;
  background: linear-gradient(90deg, #ffffff 0%, #f7fbff 24%, #7ddcff 54%, #c472ff 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.signup-funnel-brand-copy span {
  color: rgba(214, 223, 247, 0.76);
  font-size: 0.96rem;
}

.signup-funnel-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.signup-funnel-fields-basic {
  margin-top: 4px;
}

.signup-funnel-field {
  gap: 10px;
  padding: 14px;
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(22, 31, 62, 0.94), rgba(13, 19, 41, 0.98));
  border: 1px solid rgba(144, 171, 235, 0.14);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 16px 30px rgba(5, 8, 19, 0.2);
}

.signup-funnel-field span {
  color: rgba(230, 237, 255, 0.88);
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.signup-funnel-field input,
.signup-funnel-field textarea,
.signup-funnel-field select {
  min-height: 54px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(250, 250, 252, 0.98), rgba(236, 239, 246, 0.98));
  border: 1px solid rgba(205, 217, 243, 0.85);
  color: #1b2435;
  padding: 0 16px;
  box-shadow:
    inset 0 2px 0 rgba(255, 255, 255, 0.72),
    0 10px 24px rgba(8, 13, 28, 0.22);
}

.signup-funnel-field textarea {
  min-height: 140px;
  padding: 14px 16px;
  resize: vertical;
}

.signup-funnel-field-wide {
  grid-column: 1 / -1;
}

.signup-funnel-actions {
  display: grid;
  gap: 12px;
  margin-top: 2px;
}

.signup-funnel-access-actions {
  margin-bottom: 6px;
}

.signup-funnel-status {
  margin: 0;
  color: rgba(205, 218, 246, 0.82);
}

.signup-funnel-action-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px;
}

.signup-funnel-divider {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  margin: 2px 0 4px;
}

.signup-funnel-divider::before {
  content: "";
  position: absolute;
  inset: 50% 0 auto;
  border-top: 1px solid rgba(138, 162, 225, 0.14);
}

.signup-funnel-divider span {
  position: relative;
  z-index: 1;
  padding: 0 12px;
  color: rgba(194, 208, 240, 0.74);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background: linear-gradient(180deg, rgba(18, 27, 54, 0.98), rgba(10, 15, 33, 0.98));
}

.signup-funnel-primary {
  min-width: 160px;
  background: linear-gradient(135deg, #ffd08a, #ffbf66);
  color: #2d1d18;
  box-shadow: 0 16px 32px rgba(255, 188, 95, 0.22);
}

.contra-payment-modal-card {
  width: min(680px, calc(100vw - 40px));
}

.contra-payment-callout {
  display: grid;
  gap: 8px;
  margin-bottom: 14px;
  padding: 16px 18px;
  border-radius: 18px;
  border: 1px solid rgba(120, 151, 255, 0.16);
  background:
    radial-gradient(circle at top right, rgba(84, 230, 255, 0.08), transparent 32%),
    linear-gradient(180deg, rgba(30, 42, 82, 0.94), rgba(20, 28, 58, 0.96));
}

.contra-payment-callout strong {
  color: #ffffff;
  font: 700 1.02rem "Space Grotesk", sans-serif;
}

.contra-payment-callout p {
  margin: 0;
  color: rgba(214, 226, 248, 0.8);
  line-height: 1.5;
}

.contra-payment-form {
  gap: 16px;
}

.contra-payment-code-field {
  grid-column: 1 / -1;
}

.contra-payment-code-field span {
  max-width: none;
}

.profile-form {
  display: grid;
  gap: 14px;
}

.profile-form .register-actions {
  margin-top: 6px;
}

@media (max-width: 960px) {
  .signup-funnel-modal-card {
    width: min(760px, calc(100vw - 24px));
    padding: 14px;
  }

  .signup-funnel-header-grid,
  .signup-funnel-fields {
    grid-template-columns: 1fr;
  }

  .signup-funnel-brand-panel {
    justify-self: start;
  }
}

@media (max-width: 720px) {
  .signup-funnel-topbar {
    grid-template-columns: 1fr;
  }

  .signup-funnel-stepper {
    gap: 8px;
  }

  .signup-funnel-step {
    flex: 1 1 100%;
    justify-content: center;
  }

  .signup-funnel-card {
    padding: 18px 14px;
    border-radius: 24px;
  }

  .signup-funnel-copy h4 {
    font-size: clamp(1.9rem, 9vw, 2.6rem);
  }

  .signup-funnel-brand-panel {
    grid-template-columns: 60px minmax(0, 1fr);
    width: 100%;
  }

  .signup-funnel-brand-mark {
    width: 60px;
    height: 60px;
    border-radius: 18px;
  }

  .signup-funnel-brand-mark img {
    width: 40px;
    height: 40px;
  }

  .signup-funnel-action-row {
    justify-content: stretch;
  }

  .signup-funnel-action-row .primary-button,
  .signup-funnel-action-row .secondary-button {
    width: 100%;
  }
}

.create-module-modal-card {
  width: min(860px, calc(100vw - 40px));
}

.create-module-form {
  gap: 16px;
}

.create-module-description-field {
  grid-column: 1 / -1;
}

.create-module-preview {
  grid-column: 1 / -1;
}

.create-module-preview-list {
  grid-column: 1 / -1;
}

.create-marketing-project-fields {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.create-marketing-stepper {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  padding: 8px;
  border: 1px solid rgba(159, 181, 255, 0.14);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.035);
}

.create-marketing-step {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 8px 10px;
  border-radius: 12px;
  color: rgba(231, 238, 255, 0.74);
  background: transparent;
  border: 1px solid transparent;
}

.create-marketing-step span {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(235, 242, 255, 0.82);
  font-size: 0.78rem;
}

.create-marketing-step strong {
  font-size: 0.88rem;
}

.create-marketing-step.active {
  color: var(--text);
  border-color: rgba(84, 230, 255, 0.28);
  background: rgba(84, 230, 255, 0.1);
}

.create-marketing-step.active span {
  background: rgba(84, 230, 255, 0.22);
  color: #ffffff;
}

.create-marketing-project-fields [data-create-module-step] {
  display: none;
}

.create-marketing-project-fields [data-create-module-step].active {
  display: grid;
}

.create-marketing-step-panel {
  grid-column: 1 / -1;
}

.builder-onboarding-inline-action {
  grid-column: 1 / -1;
  align-items: center;
  gap: 10px;
  grid-template-columns: auto 1fr;
}

.builder-onboarding-inline-action small {
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.45;
}

.create-marketing-step-intro {
  margin: 0;
}

.create-module-form .register-actions {
  grid-column: 1 / -1;
}

.onboarding-flow-panel {
  display: grid;
  gap: 20px;
  overflow: hidden;
}

.onboarding-flow-panel::after {
  content: "";
  position: absolute;
  inset: auto 4% -24% auto;
  width: 360px;
  height: 360px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(84, 230, 255, 0.12), transparent 68%);
  pointer-events: none;
}

.onboarding-flow-head {
  position: relative;
  z-index: 1;
  gap: 20px;
}

.onboarding-flow-head h3 {
  max-width: 720px;
}

.onboarding-flow-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.onboarding-flow-layout {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(280px, 0.42fr) minmax(0, 1fr);
  gap: 18px;
  align-items: stretch;
}

.onboarding-builder-card,
.onboarding-step-card,
.builder-onboarding-callout {
  border: 1px solid rgba(159, 181, 255, 0.14);
  background:
    radial-gradient(circle at top left, rgba(83, 167, 255, 0.08), transparent 30%),
    rgba(255, 255, 255, 0.035);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.onboarding-builder-card {
  display: grid;
  gap: 14px;
  padding: 16px;
  border-radius: 24px;
}

.onboarding-builder-kicker {
  color: rgba(216, 226, 255, 0.72);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.onboarding-builder-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.onboarding-builder-tab {
  display: grid;
  gap: 4px;
  min-height: 70px;
  padding: 12px;
  text-align: left;
  color: #f7faff;
  border-radius: 16px;
  border: 1px solid rgba(159, 181, 255, 0.12);
  background: rgba(10, 18, 39, 0.62);
}

.onboarding-builder-tab.active {
  border-color: rgba(84, 230, 255, 0.52);
  background: linear-gradient(135deg, rgba(83, 167, 255, 0.22), rgba(141, 103, 255, 0.18));
  box-shadow: 0 14px 26px rgba(32, 102, 190, 0.22);
}

.onboarding-builder-tab span {
  color: rgba(204, 216, 249, 0.72);
  font-size: 0.78rem;
}

.onboarding-builder-summary {
  display: grid;
  gap: 10px;
  padding: 14px;
  border-radius: 18px;
  background: rgba(5, 11, 28, 0.64);
}

.onboarding-builder-summary > span,
.builder-onboarding-callout-head span {
  width: max-content;
  padding: 7px 9px;
  border-radius: 999px;
  color: #7ff0ff;
  background: rgba(84, 230, 255, 0.1);
  border: 1px solid rgba(84, 230, 255, 0.18);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.onboarding-builder-summary strong {
  font-size: 1.1rem;
}

.onboarding-builder-summary p,
.onboarding-step-card p,
.builder-onboarding-callout p,
.builder-onboarding-callout li {
  margin: 0;
  color: rgba(214, 224, 255, 0.78);
  line-height: 1.55;
}

.onboarding-builder-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.onboarding-builder-detail-grid div {
  display: grid;
  gap: 4px;
  padding: 10px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
}

.onboarding-builder-detail-grid small {
  color: rgba(173, 189, 232, 0.76);
}

.onboarding-step-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.onboarding-step-card {
  display: grid;
  align-content: start;
  gap: 10px;
  min-height: 220px;
  padding: 16px;
  border-radius: 22px;
}

.onboarding-step-card > span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #051021;
  font-weight: 900;
  background: linear-gradient(135deg, #69e8ff, #8dffde);
}

.onboarding-step-card strong {
  font-size: 1.02rem;
  line-height: 1.2;
}

.onboarding-step-card small {
  align-self: end;
  color: #ffc978;
  font-weight: 800;
}

.builder-onboarding-callout {
  display: grid;
  gap: 12px;
  grid-column: 1 / -1;
  padding: 16px;
  border-radius: 20px;
}

.builder-onboarding-callout-head {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

.builder-onboarding-callout ol {
  margin: 0;
  padding-left: 20px;
  columns: 2;
  column-gap: 28px;
}

.profile-avatar-field {
  grid-column: 1 / -1;
}

.workspace-home-hero {
  gap: 18px;
}

.workspace-home-hero-copy {
  display: grid;
  gap: 8px;
}

.workspace-home-action-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 8px;
}

.workspace-home-action-card {
  display: grid;
  gap: 6px;
  min-height: 108px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(182, 203, 255, 0.12);
  background:
    radial-gradient(circle at top right, rgba(92, 176, 255, 0.12), transparent 32%),
    linear-gradient(180deg, rgba(28, 37, 70, 0.92), rgba(14, 20, 40, 0.97));
}

.workspace-home-action-card span {
  color: rgba(196, 209, 239, 0.76);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.workspace-home-action-card strong {
  color: #ffffff;
  font: 700 1rem "Space Grotesk", sans-serif;
  line-height: 1.2;
}

.workspace-home-action-card small {
  color: rgba(214, 223, 247, 0.78);
  font-size: 0.82rem;
  line-height: 1.45;
}

.workspace-home-hidden {
  display: none !important;
}

.workspace-home-hero-copy h2 {
  font-size: clamp(2rem, 3vw, 2.7rem);
  color: #ffffff;
}

.workspace-home-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  gap: 16px;
}

.workspace-home-spotlight,
.workspace-home-approvals {
  display: grid;
  gap: 14px;
  padding: 18px;
  border-radius: 22px;
  border: 1px solid rgba(182, 203, 255, 0.14);
  background:
    radial-gradient(circle at top right, rgba(146, 116, 255, 0.14), transparent 34%),
    linear-gradient(180deg, rgba(31, 40, 76, 0.96), rgba(18, 24, 49, 0.98));
  box-shadow:
    0 20px 40px rgba(7, 11, 26, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.workspace-home-spotlight-head,
.workspace-home-approvals-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 12px;
  align-items: start;
}

.workspace-home-glance-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.workspace-home-glance-card {
  display: grid;
  gap: 6px;
  padding: 12px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(192, 211, 255, 0.1);
}

.workspace-home-glance-card span {
  color: rgba(212, 223, 248, 0.78);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.workspace-home-glance-card strong {
  color: #ffffff;
  font: 700 1.28rem "Space Grotesk", sans-serif;
}

.workspace-home-approval-list {
  display: grid;
  gap: 10px;
}

.workspace-home-approval-item {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
  border-radius: 16px;
  text-align: left;
  color: var(--text);
  border: 1px solid rgba(189, 210, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
}

.workspace-home-approval-item strong {
  color: #ffffff;
}

.workspace-home-approval-item small {
  color: rgba(210, 220, 246, 0.78);
}

.workspace-project-avatar svg,
.workspace-pinned-app-avatar svg,
.project-insight-icon svg {
  width: 20px;
  height: 20px;
}

.workspace-pinned-app-avatar {
  background: linear-gradient(135deg, rgba(106, 164, 255, 0.9), rgba(153, 101, 255, 0.88));
  box-shadow: 0 8px 18px rgba(48, 60, 123, 0.22);
}

.workspace-header-actions .secondary-button,
.workspace-header-actions .primary-button {
  box-shadow:
    0 14px 28px rgba(16, 22, 48, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.project-insight-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, rgba(104, 174, 255, 0.92), rgba(163, 102, 255, 0.92));
  box-shadow: 0 10px 22px rgba(54, 72, 141, 0.18);
}

.profile-avatar-picker {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) max-content;
  gap: 14px;
  align-items: center;
  padding: 12px 14px;
  border-radius: 18px;
  border: 1px solid rgba(192, 211, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
}

.profile-avatar-preview {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  color: #ffffff;
  font: 700 1.2rem "Space Grotesk", sans-serif;
  background: linear-gradient(135deg, rgba(95, 171, 255, 0.94), rgba(164, 102, 255, 0.94));
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  box-shadow: 0 14px 28px rgba(40, 53, 108, 0.24);
}

.profile-avatar-preview.has-image {
  color: transparent;
}

.profile-avatar-picker-copy {
  display: grid;
  gap: 4px;
}

.profile-avatar-picker-copy strong {
  color: #ffffff;
}

.profile-avatar-picker-copy small {
  color: rgba(210, 220, 246, 0.78);
}

.profile-avatar-upload-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

@media (max-width: 1100px) {
  .workspace-home-hero-grid,
  .workspace-home-glance-grid,
  .project-insight-stats,
  .output-review-grid {
    grid-template-columns: 1fr;
  }
}

.app-shell {
  height: 100vh;
  padding: 12px 0;
}

.workspace-shell,
.workspace-shell-inner {
  grid-template-columns: 210px minmax(0, 1fr);
  gap: 12px;
  min-height: 100%;
  height: 100%;
}

.workspace-sidebar {
  gap: 12px;
  overflow: hidden;
}

.workspace-brand-card {
  grid-template-columns: 54px minmax(0, 1fr) 42px;
  min-height: 96px;
  padding: 12px 12px 12px 14px;
  border-radius: 24px;
  background:
    linear-gradient(145deg, rgba(62, 76, 126, 0.94), rgba(24, 31, 63, 0.96)),
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), transparent);
  box-shadow:
    0 18px 40px rgba(8, 13, 33, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.1),
    inset 0 -10px 24px rgba(7, 11, 24, 0.22);
}

.workspace-brand-mark {
  width: 54px;
  height: 54px;
  border-radius: 18px;
  box-shadow:
    0 12px 26px rgba(55, 122, 210, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.workspace-brand-copy {
  gap: 3px;
}

.workspace-brand-line {
  gap: 8px;
  flex-wrap: nowrap;
}

.workspace-brand-copy h2 {
  font-size: 1.05rem;
}

.workspace-brand-tagline {
  white-space: nowrap;
  color: rgba(231, 239, 255, 0.82);
  font-size: 0.7rem;
  text-transform: none;
  letter-spacing: 0.02em;
}

.workspace-brand-copy small {
  font-size: 0.74rem;
}

.workspace-sidebar-toggle {
  width: 42px;
  height: 42px;
  padding: 0;
  border-radius: 14px;
  border-color: rgba(213, 225, 255, 0.24);
  background:
    linear-gradient(180deg, rgba(121, 136, 187, 0.42), rgba(53, 63, 109, 0.9)),
    linear-gradient(135deg, rgba(255, 255, 255, 0.08), transparent);
  color: #f9fbff;
  box-shadow:
    0 12px 24px rgba(19, 25, 56, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.18),
    inset 0 -8px 18px rgba(16, 19, 38, 0.16);
}

.workspace-sidebar-toggle svg {
  width: 18px;
  height: 18px;
  transition: transform 180ms ease;
}

body.workspace-sidebar-collapsed .workspace-sidebar-toggle svg {
  transform: rotate(180deg);
}

.workspace-nav {
  gap: 8px;
  padding: 8px;
  border-radius: 26px;
  border: 1px solid rgba(176, 198, 255, 0.12);
  background:
    linear-gradient(180deg, rgba(25, 31, 61, 0.96), rgba(14, 20, 42, 0.98));
  box-shadow:
    0 18px 40px rgba(8, 13, 33, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.workspace-nav-button {
  min-height: 60px;
  padding: 10px 12px;
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(41, 48, 82, 0.92), rgba(23, 28, 53, 0.94)),
    linear-gradient(145deg, rgba(255, 255, 255, 0.06), transparent);
  box-shadow:
    0 10px 24px rgba(14, 20, 42, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    inset 0 -8px 16px rgba(7, 10, 25, 0.18);
}

.workspace-nav-button.active {
  background:
    radial-gradient(circle at left center, rgba(176, 127, 255, 0.22), transparent 34%),
    linear-gradient(135deg, rgba(108, 122, 199, 0.98), rgba(60, 73, 132, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.16),
    inset 0 -10px 18px rgba(24, 33, 65, 0.12),
    0 20px 40px rgba(28, 34, 74, 0.18);
}

.workspace-nav-icon {
  width: 40px;
  height: 40px;
  border-radius: 13px;
}

.workspace-sidebar-section {
  padding: 14px 16px;
  gap: 12px;
  border-radius: 24px;
}

.workspace-header,
.workspace-route-chip,
.workspace-search-shell,
.workspace-user-pill,
.workspace-header .secondary-button,
.workspace-header .primary-button {
  background-image:
    linear-gradient(145deg, rgba(255, 255, 255, 0.06), transparent),
    linear-gradient(180deg, rgba(30, 37, 69, 0.96), rgba(17, 22, 44, 0.98));
}

.workspace-route-chip,
.workspace-search-shell,
.workspace-header .secondary-button,
.workspace-header .primary-button,
.workspace-user-pill {
  box-shadow:
    0 14px 28px rgba(10, 14, 33, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    inset 0 -10px 18px rgba(10, 14, 33, 0.12);
}

.workspace-project-copy strong,
.workspace-project-stat strong,
.project-insight-title strong,
.project-insight-stats strong,
.workspace-home-glance-card strong,
.workspace-home-approval-item strong {
  color: #ffffff;
}

.workspace-project-stat span,
.project-insight-stats span {
  color: rgba(223, 232, 255, 0.86);
}

#agentScreen .workspace-main {
  min-height: calc(100vh - 42px);
  grid-template-rows: max-content minmax(0, 1fr);
  overflow: hidden;
}

#dashboardScreen .workspace-main {
  min-height: calc(100vh - 42px);
  overflow: auto;
  padding-right: 0;
}

#automationScreen .workspace-main,
#reportsScreen .workspace-main {
  min-height: calc(100vh - 42px);
  overflow: auto;
  padding-right: 0;
}

.workspace-aux-shell .workspace-main {
  grid-template-rows: max-content minmax(0, 1fr);
}

.workspace-aux-panel {
  min-height: 0;
}

.workspace-embedded-grid {
  min-height: 0;
}

#dashboardScreen .workspace-panel {
  gap: 14px;
  padding: 14px;
  border-radius: 24px;
}

#dashboardScreen .workspace-home-hero {
  gap: 12px;
  padding: 16px 18px;
  border-radius: 24px;
}

#dashboardScreen .workspace-home-hero-copy h2 {
  font-size: clamp(1.75rem, 2.6vw, 2.45rem);
}

#dashboardScreen .workspace-home-spotlight,
#dashboardScreen .workspace-home-approvals {
  display: grid;
  gap: 12px;
  padding: 14px;
  border-radius: 18px;
}

#dashboardScreen .workspace-home-spotlight {
  background:
    radial-gradient(circle at top right, rgba(109, 182, 255, 0.14), transparent 34%),
    linear-gradient(180deg, rgba(34, 46, 86, 0.96), rgba(16, 22, 45, 0.98));
}

#dashboardScreen .workspace-home-approvals {
  background:
    radial-gradient(circle at top right, rgba(146, 116, 255, 0.14), transparent 34%),
    linear-gradient(180deg, rgba(34, 39, 76, 0.96), rgba(17, 22, 42, 0.98));
}

#dashboardScreen .workspace-home-glance-grid {
  gap: 10px;
}

#dashboardScreen .workspace-home-glance-card {
  min-height: 84px;
  padding: 12px;
  border-radius: 14px;
}

#dashboardScreen .workspace-home-approval-item {
  padding: 10px 12px;
  border-radius: 14px;
}

#dashboardScreen .workspace-command-center {
  gap: 12px;
  padding: 14px 16px;
  border-radius: 20px;
}

#dashboardScreen .workspace-command-side-shell {
  padding: 0;
}

#dashboardScreen .workspace-command-side-card {
  min-height: 0;
  gap: 10px;
  padding: 14px 16px;
  border-radius: 16px;
}

#dashboardScreen .workspace-project-grid {
  gap: 12px;
  align-content: start;
}

#dashboardScreen .workspace-command-layout {
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
  gap: 12px;
  align-items: start;
}

#dashboardScreen .workspace-command-main {
  gap: 10px;
}

#dashboardScreen .workspace-command-main .workspace-metric-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

#dashboardScreen .workspace-metric-card {
  min-height: 46px;
  padding: 8px 10px;
  border-radius: 14px;
}

#dashboardScreen .workspace-metric-card strong {
  font-size: 0.98rem;
}

#dashboardScreen .workspace-command-rows {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 0;
}

#dashboardScreen .workspace-command-row {
  display: inline-flex;
  grid-template-columns: none;
  gap: 8px;
  align-items: center;
  padding: 6px 10px;
  border-top: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(174, 193, 246, 0.09);
}

#dashboardScreen .workspace-command-side-head h4 {
  font-size: 0.88rem;
}

#dashboardScreen .workspace-focus-copy {
  gap: 4px;
}

#dashboardScreen .workspace-focus-copy strong {
  font-size: 0.84rem;
  line-height: 1.25;
}

#dashboardScreen .workspace-focus-copy .helper-text {
  font-size: 0.76rem;
}

#dashboardScreen .workspace-command-center .workspace-panel-head {
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 10px;
  align-items: center;
}

#dashboardScreen .workspace-command-center .workspace-panel-head .helper-text {
  display: none;
}

#dashboardScreen .workspace-command-center .eyebrow {
  margin-bottom: 2px;
}

#dashboardScreen .workspace-command-center .workspace-panel-head h3 {
  font-size: 1rem;
}

#dashboardScreen .workspace-command-row span {
  font-size: 0.8rem;
}

#dashboardScreen .workspace-command-row strong {
  font-size: 0.82rem;
}

#dashboardScreen .workspace-command-side-status {
  font-size: 0.8rem;
}

#dashboardScreen .workspace-home-grid {
  grid-template-columns: 1fr;
  gap: 12px;
}

#dashboardScreen .workspace-home-hero-grid {
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
  gap: 14px;
  align-items: start;
}

#dashboardScreen .workspace-home-hero-copy {
  gap: 10px;
}

#dashboardScreen .workspace-home-action-strip {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

#dashboardScreen .workspace-home-action-card {
  min-height: 96px;
  padding: 12px;
  border-radius: 16px;
}

#dashboardScreen .workspace-home-spotlight-head h3,
#dashboardScreen .workspace-home-approvals-head h3 {
  font-size: 1.02rem;
}

#dashboardScreen .workspace-home-spotlight-head .helper-text,
#dashboardScreen .workspace-home-approvals-head .helper-text {
  margin-top: 4px;
  font-size: 0.82rem;
  line-height: 1.4;
}

#dashboardScreen .workspace-panel > .workspace-project-grid {
  padding-bottom: 2px;
}

#dashboardScreen .workspace-home-hero-copy .helper-text,
#dashboardScreen #workspaceProjectsSummary,
#dashboardScreen #workspaceCommandSummary {
  font-size: 0.88rem;
  line-height: 1.28;
  max-width: 78ch;
}

#dashboardScreen .workspace-project-grid {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
  justify-content: stretch;
}

#dashboardScreen .workspace-home-glance-card strong {
  font-size: 1.18rem;
}

#dashboardScreen .workspace-command-side-head {
  gap: 10px;
}

#dashboardScreen .workspace-focus-copy strong {
  font-size: 0.96rem;
}

#dashboardScreen .workspace-focus-copy .helper-text {
  display: block;
  font-size: 0.82rem;
  line-height: 1.45;
}

#dashboardScreen .workspace-project-card {
  min-height: 0;
  gap: 12px;
  padding: 16px;
  border-radius: 22px;
  border-color: rgba(179, 202, 255, 0.18);
  background:
    radial-gradient(circle at top left, rgba(151, 209, 255, 0.18), transparent 34%),
    radial-gradient(circle at top right, rgba(205, 127, 255, 0.12), transparent 32%),
    linear-gradient(180deg, rgba(64, 79, 129, 0.98), rgba(30, 40, 74, 0.98));
  box-shadow:
    0 18px 34px rgba(7, 11, 26, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

#dashboardScreen .workspace-project-card.active {
  border-color: rgba(153, 214, 255, 0.34);
  background:
    radial-gradient(circle at top left, rgba(126, 198, 255, 0.24), transparent 36%),
    radial-gradient(circle at top right, rgba(214, 134, 255, 0.18), transparent 34%),
    linear-gradient(180deg, rgba(73, 96, 150, 0.99), rgba(35, 50, 89, 0.99));
}

#dashboardScreen .workspace-project-header {
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

#dashboardScreen .workspace-project-avatar {
  width: 44px;
  height: 44px;
  border-radius: 14px;
}

#dashboardScreen .workspace-project-copy {
  gap: 5px;
}

#dashboardScreen .workspace-project-copy strong {
  font-size: 1.08rem;
}

#dashboardScreen .workspace-project-description {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  white-space: normal;
  text-overflow: unset;
  font-size: 0.85rem;
  line-height: 1.28;
  max-width: 30ch;
}

#dashboardScreen .workspace-project-chip {
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.72rem;
  color: #f2f6ff;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.04));
  border-color: rgba(195, 210, 251, 0.14);
}

#dashboardScreen .workspace-project-stats {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  justify-content: stretch;
  gap: 8px;
}

@media (max-width: 1680px) {
  #dashboardScreen .workspace-home-hero-grid {
    grid-template-columns: 1fr;
  }

  #dashboardScreen .workspace-home-glance-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #dashboardScreen .workspace-home-spotlight-head,
  #dashboardScreen .workspace-home-approvals-head,
  #dashboardScreen .workspace-command-center .workspace-panel-head,
  #dashboardScreen .workspace-command-side-head {
    grid-template-columns: 1fr;
  }

  #dashboardScreen .workspace-command-layout {
    grid-template-columns: 1fr;
  }

  #dashboardScreen .workspace-command-main .workspace-metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #dashboardScreen .workspace-command-badge,
  #dashboardScreen .workspace-command-side-status,
  #dashboardScreen .workspace-home-approval-count {
    white-space: normal;
  }
}

@media (max-width: 1440px) {
  #dashboardScreen .workspace-home-action-strip,
  #dashboardScreen .workspace-home-glance-grid,
  #dashboardScreen .workspace-command-main .workspace-metric-grid {
    grid-template-columns: 1fr;
  }

  #dashboardScreen .workspace-project-grid {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  }
}

#dashboardScreen .workspace-project-stat {
  padding: 8px 9px 7px;
  border-radius: 13px;
  background:
    linear-gradient(180deg, rgba(17, 23, 45, 0.88), rgba(11, 16, 32, 0.92));
  border-color: rgba(193, 209, 249, 0.08);
}

#dashboardScreen .workspace-project-stat strong {
  font-size: 1rem;
}

#dashboardScreen .workspace-project-stat span {
  font-size: 0.68rem;
}

#dashboardScreen .workspace-project-footer {
  font-size: 0.8rem;
  color: rgba(229, 236, 255, 0.86);
}

#dashboardScreen .workspace-project-menu {
  color: rgba(244, 248, 255, 0.74);
}

#agentScreen .workspace-header .release-pill,
#agentScreen #backToDashboardFromAgent {
  display: none;
}

#agentScreen .workspace-header {
  grid-template-columns: max-content minmax(260px, 1fr) max-content;
  gap: 12px;
}

#agentScreen .workspace-header-actions {
  gap: 8px;
}

#agentScreen .workspace-header .secondary-button {
  min-height: 38px;
  padding: 0 14px;
  border-radius: 14px;
}

.agent-workspace-panel {
  min-height: 0;
  height: 100%;
  padding: 12px;
}

.agent-workspace-shell {
  display: grid;
  grid-template-columns: 228px minmax(0, 1.5fr) 320px;
  gap: 12px;
  min-height: 0;
  height: 100%;
}

.agent-workspace-shell.revenue-layout-compact {
  grid-template-columns: minmax(0, 1fr);
}

.agent-workspace-shell.revenue-layout-compact .agent-side-rail,
.agent-workspace-shell.revenue-layout-compact .agent-output-rail {
  display: none;
}

.agent-workspace-shell.revenue-layout-pipeline {
  grid-template-columns: 238px minmax(0, 1fr);
}

.agent-workspace-shell.revenue-layout-pipeline .agent-output-rail {
  display: none;
}

.agent-side-rail,
.agent-center-stage,
.agent-output-rail {
  display: grid;
  gap: 14px;
  min-height: 0;
}

.agent-project-browser,
.agent-side-panel,
.agent-project-stage,
.agent-queue-panel,
.agent-review-panel,
.agent-workflow-panel {
  display: grid;
  gap: 10px;
  min-height: 0;
  overflow: hidden;
}

.agent-project-browser {
  grid-template-rows: max-content minmax(0, 1fr);
}

.agent-project-browser-list,
.agent-bucket-browser,
.agent-node-browser,
#agentRunsList,
#agentOutputsList,
.agent-detail-sections,
.agent-editor-content-list {
  min-height: 0;
  overflow: auto;
  scrollbar-width: thin;
}

.agent-project-browser-card {
  text-align: left;
  padding: 12px;
  gap: 10px;
}

.agent-project-browser-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.agent-project-browser-copy strong {
  color: #ffffff;
  font-size: 0.98rem;
}

.agent-project-browser-copy p {
  margin: 0;
  color: rgba(220, 228, 246, 0.82);
  font-size: 0.82rem;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.agent-project-browser-card .project-insight-stats div {
  padding: 8px 10px;
}

.agent-side-summary {
  gap: 6px;
}

.agent-bucket-card,
.agent-node-card {
  text-align: left;
}

.agent-frequency-input input {
  min-height: 42px;
}

.agent-cadence-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px 12px;
  align-items: center;
}

.agent-cadence-actions .helper-text {
  margin: 0;
  max-width: 280px;
}

.agent-project-stage {
  grid-template-rows: max-content minmax(0, 1fr);
}

.agent-project-stage-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 14px;
  align-items: start;
}

.agent-stage-badges {
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 6px;
}

.agent-module-overview-compact {
  gap: 10px;
}

.agent-module-mini-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.agent-mini-panel {
  padding: 12px;
  border-radius: 18px;
  border: 1px solid rgba(176, 203, 255, 0.12);
  background:
    linear-gradient(180deg, rgba(34, 41, 74, 0.94), rgba(20, 26, 50, 0.96));
}

.module-overview-copy p,
#agentWorkflowSubtitle,
#agentModuleSummary,
#agentModuleStatusMeta {
  margin: 0;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.module-overview-copy h4,
#agentWorkflowTitle {
  margin: 0;
}

.agent-queue-panel {
  grid-template-rows: max-content minmax(0, 1fr);
}

.agent-queue-entry summary {
  padding: 12px 14px;
}

.agent-review-panel {
  grid-template-rows: max-content minmax(0, 1fr) max-content;
}

.output-review-card strong,
.project-queue-head strong,
.module-overview-copy h4,
.module-overview-status strong,
.module-signal-head strong,
.module-rule-head strong,
.detail-kpi strong {
  color: #ffffff;
}

.agent-detail-sections {
  display: grid;
  gap: 10px;
}

.agent-detail-block {
  display: grid;
  gap: 10px;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid rgba(176, 203, 255, 0.1);
  background:
    linear-gradient(180deg, rgba(34, 41, 74, 0.9), rgba(20, 25, 49, 0.94));
}

.agent-detail-block-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 10px;
  align-items: center;
  cursor: pointer;
  list-style: none;
}

.agent-detail-block-head::-webkit-details-marker {
  display: none;
}

.agent-detail-block summary + * {
  min-height: 0;
}

.agent-detail-block:not([open]) .module-signal-list,
.agent-detail-block:not([open]) .module-rule-list,
.agent-detail-block:not([open]) .agent-node-browser,
.agent-config-block:not([open]) form,
.agent-config-block:not([open]) .summary-list {
  display: none;
}

.agent-node-mini-form {
  gap: 10px;
}

.agent-node-mini-form textarea {
  min-height: 88px;
}

.agent-auth-summary {
  display: grid;
  gap: 10px;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid rgba(176, 203, 255, 0.1);
  background:
    linear-gradient(180deg, rgba(34, 41, 74, 0.9), rgba(20, 25, 49, 0.94));
}

.agent-key-form {
  grid-template-columns: minmax(0, 1fr) max-content;
  align-items: end;
}

.marketing-auth-shell {
  display: grid;
  gap: 12px;
}

.marketing-auth-provider-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.marketing-auth-tab {
  display: inline-grid;
  gap: 6px;
  justify-items: start;
  min-width: 0;
}

.marketing-auth-tab-label-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.marketing-auth-tab-label-row strong {
  color: #ffffff;
  font: 700 0.94rem "Space Grotesk", sans-serif;
}

.marketing-auth-tab.active {
  border-color: rgba(120, 186, 255, 0.38);
  background: rgba(120, 186, 255, 0.12);
  color: #ffffff;
}

.marketing-auth-tab[data-tone="warning"] {
  box-shadow: inset 0 0 0 1px rgba(255, 133, 165, 0.12);
}

.marketing-auth-tab[data-tone="positive"] {
  box-shadow: inset 0 0 0 1px rgba(100, 223, 178, 0.12);
}

.marketing-auth-tab small {
  color: var(--muted);
  font-size: 0.72rem;
}

.marketing-auth-provider-summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 12px;
  align-items: start;
  padding: 12px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.032);
  box-shadow: inset 0 0 0 1px rgba(176, 203, 255, 0.08);
}

.marketing-auth-provider-headline {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.marketing-auth-provider-requirement {
  color: rgba(205, 216, 244, 0.72);
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.marketing-auth-provider-copy {
  display: grid;
  gap: 8px;
}

.marketing-auth-provider-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.marketing-auth-provider-metrics span {
  min-width: 0;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  box-shadow: inset 0 0 0 1px rgba(176, 203, 255, 0.08);
}

.marketing-auth-provider-metrics small {
  display: block;
  color: rgba(181, 194, 228, 0.74);
  font-size: 0.66rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.marketing-auth-provider-metrics strong {
  display: block;
  margin-top: 6px;
  color: #ffffff;
  font-size: 0.92rem;
  overflow-wrap: anywhere;
}

.marketing-auth-provider-actions {
  display: grid;
  justify-items: end;
  align-content: start;
  gap: 8px;
}

.marketing-auth-provider-actions .secondary-button,
.marketing-auth-provider-actions .primary-button {
  min-width: 158px;
}

.marketing-auth-redirect {
  display: grid;
  gap: 4px;
  margin-top: 4px;
}

.marketing-auth-redirect span {
  color: var(--muted);
  font-size: 0.75rem;
}

.marketing-auth-redirect code {
  display: inline-block;
  width: fit-content;
  max-width: 100%;
  overflow-wrap: anywhere;
  padding: 6px 8px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(176, 203, 255, 0.14);
  color: #f3f7ff;
  font-size: 0.76rem;
}

.marketing-auth-identity {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  margin-top: 8px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(176, 203, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
}

.marketing-auth-identity.connected {
  border-color: rgba(112, 230, 177, 0.28);
  background: rgba(112, 230, 177, 0.08);
}

.marketing-auth-identity div {
  display: grid;
  gap: 4px;
}

.marketing-auth-identity strong {
  color: #ffffff;
}

.marketing-auth-identity small {
  color: var(--muted);
  line-height: 1.45;
}

.marketing-auth-fields {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 1180px) {
  .marketing-auth-fields {
    grid-template-columns: 1fr;
  }

  .marketing-publish-success-bar,
  .marketing-selection-bar,
  .marketing-active-review-bar {
    grid-template-columns: 1fr;
  }

  .marketing-publish-success-actions,
  .marketing-active-review-actions {
    grid-auto-flow: row;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.marketing-auth-field {
  position: relative;
  gap: 6px;
  padding: 12px;
  border-radius: 16px;
}

.marketing-auth-field-head {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.marketing-auth-field-label {
  color: #eef3ff;
  font-weight: 600;
}

.marketing-help-inline {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
}

.marketing-help-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  border: 1px solid rgba(176, 203, 255, 0.22);
  background: rgba(255, 255, 255, 0.06);
  color: #d9e8ff;
  font-size: 0.72rem;
  font-weight: 700;
}

.marketing-help-popover {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 10px);
  transform: translateX(-50%);
  width: min(280px, 72vw);
  display: none;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(8, 13, 28, 0.98);
  border: 1px solid rgba(176, 203, 255, 0.18);
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.35);
  z-index: 12;
}

.marketing-help-popover:not(.hidden) {
  display: block;
}

.marketing-help-popover strong,
.marketing-help-popover span {
  display: block;
}

.marketing-help-popover strong {
  color: #ffffff;
  margin-bottom: 4px;
}

.marketing-help-popover span {
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.45;
}

.marketing-help-popover a {
  display: inline-flex;
  margin-top: 8px;
  color: #8fc7ff;
  font-size: 0.76rem;
  font-weight: 600;
  text-decoration: underline;
}

.marketing-help-inline:hover .marketing-help-popover,
.marketing-help-inline:focus-within .marketing-help-popover {
  display: block;
}

.marketing-auth-field-copy {
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.45;
}

.marketing-auth-field-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 6px 10px;
  align-items: center;
  font-size: 0.74rem;
}

.marketing-auth-field-note {
  color: var(--muted);
}

.marketing-auth-field-footer a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

.marketing-auth-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  position: sticky;
  bottom: 0;
  padding-top: 8px;
  background: linear-gradient(180deg, rgba(15, 21, 45, 0), rgba(15, 21, 45, 0.96) 32%);
}

.marketing-auth-actions .helper-text {
  max-width: 360px;
  font-size: 0.76rem;
}

.workspace-refreshing {
  animation: workspace-refresh-pulse 340ms ease;
}

@keyframes workspace-refresh-pulse {
  0% {
    opacity: 0.72;
    transform: translateY(8px) scale(0.995);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.agent-editor-modal-card {
  width: min(1320px, calc(100vw - 40px));
  max-height: calc(100vh - 36px);
  overflow: hidden;
  background:
    radial-gradient(circle at top right, rgba(170, 117, 255, 0.14), transparent 30%),
    linear-gradient(180deg, rgba(24, 30, 60, 0.98), rgba(12, 17, 36, 0.99));
}

.agent-editor-modal-grid {
  display: grid;
  grid-template-columns: 220px minmax(0, 1.18fr) minmax(320px, 0.84fr);
  gap: 14px;
  min-height: 0;
  max-height: calc(100vh - 150px);
}

.agent-editor-modal-column {
  display: grid;
  gap: 12px;
  min-height: 0;
  overflow: auto;
}

.agent-editor-modal-column--library {
  align-content: start;
}

.agent-editor-modal-column--editor {
  grid-template-rows: max-content max-content minmax(0, 1fr) max-content;
}

.agent-editor-content-list {
  display: grid;
  gap: 10px;
}

.agent-editor-modal-column textarea {
  resize: vertical;
}

.agent-editor-compact-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.agent-editor-compact-head strong {
  color: rgba(240, 245, 255, 0.96);
  font: 700 1rem "Space Grotesk", sans-serif;
}

.agent-editor-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0 12px;
}

.agent-editor-toolbar-button {
  min-height: 34px;
  padding-inline: 12px;
  font-size: 0.8rem;
}

.agent-editor-actions-sticky {
  position: sticky;
  bottom: 0;
  z-index: 4;
  padding: 12px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(13, 18, 38, 0.56), rgba(13, 18, 38, 0.96));
  box-shadow: 0 -16px 28px rgba(8, 12, 24, 0.18);
}

.workspace-shell,
.workspace-shell-inner {
  grid-template-columns: 250px minmax(0, 1fr);
}

.workspace-brand-card {
  min-height: 88px;
  grid-template-columns: 52px minmax(0, 1fr) 40px;
}

.workspace-brand-copy h2 {
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(207, 198, 255, 0.96) 48%, rgba(153, 121, 255, 0.96));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.workspace-brand-tagline {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  color: rgba(237, 241, 255, 0.9);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
}

.workspace-nav {
  gap: 6px;
}

.workspace-nav-button {
  min-height: 50px;
  padding: 8px 12px;
  border-radius: 16px;
}

.workspace-nav-icon {
  width: 36px;
  height: 36px;
  border-radius: 12px;
}

.workspace-nav-copy strong {
  font-size: 0.96rem;
}

.workspace-header {
  grid-template-columns: max-content minmax(340px, 1fr) max-content;
}

.workspace-utility-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  min-height: 54px;
  padding: 6px;
  border-radius: 18px;
  border: 1px solid rgba(176, 198, 255, 0.12);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.04), transparent),
    linear-gradient(180deg, rgba(24, 30, 58, 0.96), rgba(13, 18, 39, 0.98));
  box-shadow:
    0 14px 28px rgba(10, 14, 33, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.07),
    inset 0 -10px 18px rgba(10, 14, 33, 0.12);
}

.workspace-utility-pill {
  display: grid;
  gap: 2px;
  align-content: center;
  min-width: 0;
  padding: 8px 12px;
  border-radius: 14px;
  background:
    linear-gradient(180deg, rgba(38, 46, 81, 0.88), rgba(23, 28, 53, 0.94));
  border: 1px solid rgba(182, 203, 255, 0.08);
}

.workspace-utility-pill span {
  color: rgba(172, 186, 225, 0.82);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.56rem;
}

.workspace-utility-pill strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: rgba(244, 248, 255, 0.96);
  font: 700 0.9rem "Space Grotesk", sans-serif;
}

.workspace-admin-button,
.workspace-header .workspace-admin-button {
  color: rgba(248, 250, 255, 0.98);
  font-weight: 700;
}

.workspace-user-copy small {
  color: rgba(227, 233, 246, 0.84);
}

.workspace-user-copy strong,
.workspace-user-label {
  color: rgba(248, 250, 255, 0.98);
}

.workspace-user-pill {
  min-width: 168px;
}

.workspace-user-dropdown-item {
  color: rgba(244, 247, 255, 0.96);
}

body.workspace-sidebar-collapsed .workspace-shell,
body.workspace-sidebar-collapsed .workspace-shell-inner {
  grid-template-columns: 86px minmax(0, 1fr);
}

body.workspace-sidebar-collapsed .workspace-nav {
  padding: 6px;
}

body.workspace-sidebar-collapsed .workspace-brand-card {
  padding: 12px 8px;
}

@media (max-width: 1500px) {
  .agent-workspace-shell {
    grid-template-columns: 210px minmax(0, 1.35fr) 300px;
  }
}

@media (max-width: 1320px) {
  #agentScreen .workspace-main {
    overflow: visible;
  }

  .agent-workspace-panel {
    height: auto;
  }

  .agent-workspace-shell,
  .agent-editor-modal-grid {
    grid-template-columns: 1fr;
    height: auto;
  }

  .workspace-utility-strip {
    grid-template-columns: 1fr;
  }

  .agent-side-rail,
  .agent-center-stage,
  .agent-output-rail {
    min-height: auto;
  }

  .agent-module-mini-grid,
  .agent-key-form {
    grid-template-columns: 1fr;
  }
}

/* Studio refresh: compact brand tray, navigable utility pills, split overview/project modes */
.workspace-brand-copy {
  min-width: 0;
}

.workspace-brand-line {
  align-items: center;
  gap: 10px;
  flex-wrap: nowrap;
}

.workspace-brand-copy small {
  color: rgba(185, 196, 222, 0.76);
  font-size: 0.8rem;
  white-space: nowrap;
}

.workspace-brand-tagline {
  display: block;
  margin-top: 2px;
}

.workspace-nav {
  gap: 8px;
  padding: 10px;
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(18, 24, 45, 0.94), rgba(10, 14, 30, 0.96)),
    linear-gradient(145deg, rgba(255, 255, 255, 0.04), transparent);
}

.workspace-nav-button {
  min-height: 48px;
  padding: 8px 10px;
  border-radius: 14px;
}

.workspace-nav-copy small {
  color: rgba(172, 185, 214, 0.72);
}

.workspace-nav-copy strong {
  color: rgba(248, 250, 255, 0.98);
}

.workspace-utility-pill {
  width: 100%;
  text-align: left;
  cursor: pointer;
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.workspace-utility-pill:hover {
  transform: translateY(-1px);
  border-color: rgba(208, 220, 255, 0.2);
  box-shadow: 0 12px 24px rgba(12, 16, 36, 0.16);
}

.agent-studio-overview-shell {
  display: block;
  gap: 12px;
  min-height: 0;
  height: 100%;
}

.agent-studio-overview-shell.hidden,
.agent-workspace-shell.hidden {
  display: none;
}

.agent-studio-settings-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.agent-studio-settings-list,
.agent-studio-action-list,
.agent-studio-module-catalog,
.workspace-utility-modal-list {
  display: grid;
  gap: 10px;
}

.agent-studio-setting-card,
.agent-studio-action-card,
.agent-studio-module-card,
.workspace-utility-modal-item {
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(180, 196, 244, 0.12);
  background:
    linear-gradient(180deg, rgba(34, 40, 74, 0.92), rgba(18, 24, 47, 0.95)),
    linear-gradient(145deg, rgba(255, 255, 255, 0.04), transparent);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 12px 26px rgba(10, 14, 30, 0.12);
}

button.agent-studio-action-card,
button.workspace-utility-modal-item,
button.workspace-utility-pill {
  appearance: none;
  color: inherit;
}

button.agent-studio-action-card,
button.workspace-utility-modal-item {
  width: 100%;
  text-align: left;
  cursor: pointer;
}

.agent-studio-setting-card strong,
.agent-studio-action-card strong,
.agent-studio-module-card strong,
.workspace-utility-modal-item strong {
  color: rgba(248, 251, 255, 0.98);
}

.agent-studio-setting-card p,
.agent-studio-action-card p,
.agent-studio-module-card p,
.workspace-utility-modal-item p {
  margin: 2px 0 0;
  color: rgba(181, 191, 219, 0.82);
}

.agent-studio-catalog-panel {
  min-height: 0;
}

.agent-studio-catalog-panel--full {
  display: grid;
  gap: 14px;
}

.agent-studio-overview-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.agent-studio-overview-mini-stats {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.agent-studio-mini-stat {
  appearance: none;
  display: grid;
  gap: 1px;
  align-content: center;
  min-width: 62px;
  min-height: 34px;
  padding: 4px 8px;
  border-radius: 11px;
  border: 1px solid rgba(191, 205, 248, 0.16);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02) 30%, transparent 34%),
    linear-gradient(180deg, rgba(48, 54, 92, 0.98), rgba(24, 30, 56, 0.98));
  color: inherit;
  cursor: pointer;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 10px 18px rgba(9, 13, 30, 0.12);
}

.agent-studio-mini-stat span {
  color: rgba(170, 184, 220, 0.74);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.5rem;
  line-height: 1;
}

.agent-studio-mini-stat strong {
  color: rgba(248, 251, 255, 0.98);
  font-size: 0.82rem;
  line-height: 1.05;
}

.agent-studio-overview-toolbar {
  display: grid;
  gap: 10px;
}

.agent-studio-setting-card {
  padding: 10px 12px;
  border-radius: 12px;
}

.agent-studio-setting-card .eyebrow {
  margin-bottom: 6px;
}

.agent-studio-setting-card strong {
  display: block;
  font-size: 1.15rem;
  line-height: 1;
}

.agent-studio-setting-card p {
  font-size: 0.78rem;
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.agent-studio-settings-list {
  gap: 10px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.agent-studio-setting-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 12px;
  border-radius: 12px;
  border: 1px solid rgba(180, 196, 244, 0.1);
  background: rgba(15, 20, 41, 0.55);
}

.agent-studio-setting-row--cta {
  width: 100%;
}

.agent-studio-setting-cta {
  appearance: none;
  cursor: pointer;
  min-width: 112px;
  text-align: center;
}

button.agent-studio-setting-row {
  width: 100%;
  text-align: left;
  cursor: pointer;
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

button.agent-studio-setting-row:hover {
  transform: translateY(-1px);
  border-color: rgba(199, 214, 255, 0.22);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 12px 20px rgba(8, 12, 28, 0.14);
}

.agent-studio-setting-row .pill {
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

button.agent-studio-setting-row:hover .pill {
  transform: translateY(-1px);
}

.agent-studio-setting-row-head,
.agent-studio-action-card-headline,
.agent-studio-module-summary-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.agent-studio-setting-row-head {
  min-width: 0;
  flex: 1;
}

.agent-studio-setting-row strong {
  font-size: 0.94rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.agent-studio-setting-row p {
  margin: 0;
  font-size: 0.76rem;
  line-height: 1.1;
  color: rgba(181, 191, 219, 0.82);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.agent-studio-setting-row-copy {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.agent-studio-module-card {
  display: grid;
  gap: 10px;
  text-align: left;
  cursor: pointer;
  min-height: 0;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    box-shadow 180ms ease;
}

.agent-studio-module-card:hover,
.agent-studio-module-card:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(142, 172, 255, 0.24);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 18px 34px rgba(10, 14, 30, 0.18);
}

.agent-studio-module-head,
.agent-studio-module-foot,
.agent-studio-action-head,
.workspace-utility-modal-item-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.agent-studio-module-title {
  display: flex;
  gap: 12px;
  min-width: 0;
}

.agent-studio-module-copy {
  min-width: 0;
}

.agent-studio-module-copy strong,
.agent-studio-module-copy p {
  display: block;
}

.agent-studio-module-copy strong {
  font-size: 1rem;
  line-height: 1.08;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.agent-studio-module-copy p {
  font-size: 0.78rem;
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.agent-studio-module-catalog {
  grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
  align-content: start;
}

.agent-studio-module-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
}

.agent-studio-module-stat {
  padding: 6px 8px;
  border-radius: 12px;
  background: rgba(14, 19, 38, 0.34);
  border: 1px solid rgba(182, 197, 243, 0.08);
  min-width: 0;
}

.agent-studio-module-stat span {
  display: block;
  color: rgba(170, 183, 216, 0.72);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.agent-studio-module-stat strong {
  display: block;
  margin-top: 3px;
  font-size: 0.88rem;
  line-height: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.agent-studio-module-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.agent-studio-module-foot {
  align-items: center;
}

.agent-studio-module-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.agent-studio-module-status strong {
  font-size: 0.9rem;
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.agent-studio-module-status span,
.agent-studio-module-summary-row span {
  color: rgba(171, 184, 217, 0.8);
  font-size: 0.8rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.agent-studio-module-summary-row {
  color: rgba(171, 184, 217, 0.82);
  font-size: 0.8rem;
}

#agentScreen .workspace-utility-strip {
  grid-template-columns: repeat(3, minmax(118px, 152px));
  justify-content: start;
  gap: 8px;
}

#agentScreen .workspace-utility-pill {
  gap: 1px;
  min-height: 44px;
  padding: 6px 10px;
  border-radius: 12px;
  border-color: rgba(194, 209, 255, 0.14);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02) 28%, transparent 32%),
    linear-gradient(180deg, rgba(34, 41, 76, 0.96), rgba(18, 23, 45, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    inset 0 -10px 18px rgba(6, 11, 28, 0.12),
    0 10px 20px rgba(10, 14, 32, 0.12);
}

#agentScreen .workspace-utility-pill span {
  font-size: 0.49rem;
  letter-spacing: 0.14em;
}

#agentScreen .workspace-utility-pill strong {
  font-size: 0.8rem;
  line-height: 1.05;
}

#agentScreen .workspace-header-actions {
  gap: 8px;
}

#agentScreen .workspace-header-primary,
#agentScreen .workspace-header .secondary-button {
  min-height: 38px;
  padding: 0 14px;
  border-radius: 14px;
  font-size: 0.88rem;
}

#agentScreen .workspace-header-primary,
#agentScreen #agentStudioCreateModuleButton {
  color: #ffffff;
  background:
    linear-gradient(135deg, rgba(160, 210, 255, 0.99), rgba(186, 166, 255, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.18),
    0 14px 24px rgba(118, 144, 255, 0.18);
}

#agentScreen .agent-studio-overview-shell {
  gap: 8px;
}

#agentScreen .agent-studio-catalog-panel--full {
  gap: 10px;
}

#agentScreen .agent-studio-overview-toolbar {
  gap: 8px;
}

#agentScreen .agent-studio-settings-grid {
  gap: 6px;
}

#agentScreen .agent-studio-setting-card {
  padding: 8px 10px;
  border-radius: 10px;
}

#agentScreen .agent-studio-setting-card strong {
  font-size: 1rem;
}

#agentScreen .agent-studio-setting-card p {
  font-size: 0.72rem;
}

#agentScreen .agent-studio-settings-list {
  gap: 8px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

#agentScreen .agent-studio-setting-row {
  padding: 9px 10px;
  border-radius: 10px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.015) 34%, transparent 38%),
    linear-gradient(180deg, rgba(32, 38, 70, 0.96), rgba(18, 23, 44, 0.98));
}

#agentScreen .agent-studio-setting-row .pill:not(.live) {
  background:
    linear-gradient(135deg, rgba(99, 162, 255, 0.92), rgba(132, 105, 255, 0.92));
  color: #ffffff;
  border-color: rgba(168, 194, 255, 0.22);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    0 10px 16px rgba(74, 95, 255, 0.16);
}

#agentScreen .agent-studio-setting-row strong {
  font-size: 0.86rem;
}

#agentScreen .agent-studio-setting-row p {
  font-size: 0.72rem;
}

#agentScreen .agent-studio-module-catalog {
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 12px;
  width: 100%;
  align-items: stretch;
}

#agentScreen .agent-studio-module-card {
  gap: 10px;
  padding: 14px;
  border-radius: 14px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.03) 24%, transparent 34%),
    linear-gradient(180deg, rgba(60, 66, 110, 0.98), rgba(28, 33, 61, 0.99));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    inset 0 -14px 20px rgba(8, 12, 30, 0.12),
    0 14px 28px rgba(9, 13, 30, 0.12);
}

#agentScreen .agent-studio-module-card--create {
  min-height: 116px;
  align-content: center;
  border-style: dashed;
  border-color: rgba(139, 218, 255, 0.3);
  background:
    linear-gradient(180deg, rgba(39, 55, 91, 0.8), rgba(19, 26, 49, 0.92));
}

#agentScreen .agent-studio-module-head,
#agentScreen .agent-studio-module-foot,
#agentScreen .agent-studio-module-summary-row {
  gap: 8px;
}

#agentScreen .agent-studio-module-copy strong {
  font-size: 0.94rem;
}

#agentScreen .agent-studio-module-copy p {
  font-size: 0.74rem;
  white-space: normal;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

#agentScreen .agent-studio-module-stats {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
}

#agentScreen .agent-studio-module-stat {
  padding: 4px 6px;
  border-radius: 10px;
  background:
    linear-gradient(180deg, rgba(24, 29, 52, 0.95), rgba(13, 18, 35, 0.98));
  border-color: rgba(185, 201, 247, 0.07);
}

#agentScreen .agent-studio-module-stat span {
  font-size: 0.52rem;
  letter-spacing: 0.07em;
}

#agentScreen .agent-studio-module-stat strong {
  margin-top: 2px;
  font-size: 0.74rem;
}

#agentScreen .agent-studio-module-status strong,
#agentScreen .agent-studio-module-summary-row,
#agentScreen .agent-studio-module-status span,
#agentScreen .agent-studio-module-summary-row span {
  font-size: 0.72rem;
}

#agentScreen .agent-studio-module-foot {
  min-width: 0;
}

#agentScreen .agent-studio-module-status {
  display: grid;
  gap: 3px;
}

#agentScreen .agent-studio-module-status span {
  white-space: normal;
  line-height: 1.25;
}

#agentScreen .agent-studio-module-actions .pill {
  white-space: nowrap;
}

#agentScreen .agent-studio-catalog-panel--full {
  overflow: hidden;
}

#agentScreen .agent-studio-overview-shell .panel-head.compact {
  align-items: center;
  padding-inline: 2px;
}

#agentScreen .agent-studio-overview-actions {
  justify-content: flex-end;
}

.create-marketing-project-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.create-marketing-project-fields.hidden {
  display: none;
}

.create-marketing-project-fields .toggle-card {
  grid-column: 1 / -1;
}

.agent-workspace-shell[data-studio-mode="project"] .agent-project-browser {
  display: none;
}

.agent-workspace-shell[data-studio-mode="project"] {
  grid-template-columns: 260px minmax(0, 1.55fr) 320px;
}

.workspace-utility-modal-card {
  width: min(720px, calc(100vw - 48px));
  max-height: min(78vh, 820px);
  display: grid;
  gap: 14px;
}

.workspace-utility-modal-list {
  overflow: auto;
  padding-right: 4px;
}

.workspace-utility-modal-item-meta {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  color: rgba(178, 189, 219, 0.8);
  font-size: 0.84rem;
}

@media (max-width: 1500px) {
  .agent-studio-module-catalog {
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  }
}

@media (max-width: 1320px) {
  .agent-studio-module-catalog {
      grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    }

    .agent-studio-settings-list {
      grid-template-columns: 1fr;
    }
  }

@media (max-width: 760px) {
  .agent-studio-settings-grid,
  .agent-studio-module-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Login tightening pass: keep auth screen single-view and remove right-card bloat */
.auth-layout-dark {
  min-height: calc(100vh - 32px);
  grid-template-columns: minmax(0, 1.28fr) minmax(320px, 360px);
  gap: 16px;
  align-items: stretch;
}

.auth-hero-card {
  min-height: 0;
  gap: 12px;
  padding: 18px 20px;
}

.auth-hero-card h1 {
  margin: 0;
  max-width: 780px;
  font-size: clamp(1.7rem, 2.1vw, 2.1rem);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.auth-brand-stage {
  min-height: 108px;
  border-radius: 22px;
}

.hero-text {
  margin: 0;
  max-width: 760px;
  font-size: 0.88rem;
  line-height: 1.34;
}

.hero-badges {
  gap: 10px;
}

.hero-badges .pill {
  padding: 8px 10px;
}

.auth-highlight-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.auth-highlight-card,
.auth-lane-card,
.auth-proof-metric {
  padding: 10px 12px;
}

.auth-lane-grid,
.auth-proof-strip {
  gap: 10px;
}

.auth-proof-strip {
  display: none;
}

.auth-stack {
  width: min(350px, 100%);
  gap: 10px;
  align-self: center;
}

.auth-entry-card,
#registerForm.auth-card-shell {
  padding: 16px;
  gap: 10px;
}

.auth-entry-card h2 {
  margin: 0;
  font-size: 1.1rem;
  line-height: 1.12;
  white-space: nowrap;
}

.auth-entry-heading {
  letter-spacing: -0.03em;
}

.auth-entry-heading span {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(198, 224, 255, 0.98) 46%, rgba(140, 120, 255, 0.98));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.auth-entry-card .helper-text {
  margin: 0;
  font-size: 0.8rem;
  line-height: 1.2;
  white-space: nowrap;
}

.auth-form-grid {
  gap: 8px;
}

.auth-entry-card .field,
#registerForm .field {
  gap: 5px;
}

.auth-entry-card .field span,
#registerForm .field span {
  font-size: 0.88rem;
}

.auth-entry-card input,
#registerForm input {
  min-height: 44px;
  padding: 10px 14px;
}

.auth-entry-card .primary-button,
.auth-entry-card .secondary-button,
#registerForm .primary-button,
#registerForm .secondary-button {
  min-height: 44px;
  padding: 10px 14px;
}

.auth-divider {
  margin-top: 2px;
}

.auth-divider span {
  font-size: 0.78rem;
}

.auth-highlight-card strong,
.auth-lane-card strong {
  font-size: 1rem;
  line-height: 1.22;
}

.auth-highlight-card > span,
.auth-lane-card > span {
  font-size: 0.9rem;
  line-height: 1.4;
}

.auth-highlight-card-featured .auth-highlight-tags {
  display: none;
}

.auth-lane-card {
  gap: 6px;
}

.auth-lane-card span:last-child {
  color: rgba(196, 206, 233, 0.8);
}

@media (max-width: 1400px) {
  .auth-layout-dark {
    grid-template-columns: minmax(0, 1.18fr) 340px;
  }

  .auth-hero-card {
    padding: 18px 20px;
  }
}

.auth-brand-stage::before {
  width: 46%;
  height: 46%;
}

.auth-brand-stage::after {
  width: 64%;
  height: 64%;
}

.auth-brand-core {
  gap: 8px;
}

.auth-brand-mark {
  width: 76px;
  height: 76px;
  padding: 10px;
  border-radius: 24px;
}

.auth-brand-caption {
  gap: 2px;
}

.auth-brand-caption span {
  font-size: 0.66rem;
}

.auth-brand-caption strong {
  font-size: 0.88rem;
  max-width: 240px;
}

.auth-brand-orbit {
  padding: 6px 10px;
  font-size: 0.7rem;
}

.auth-brand-orbit-a { top: 10px; left: 20px; }
.auth-brand-orbit-b { top: 12px; right: 20px; }
.auth-brand-orbit-c { bottom: 16px; left: 26px; }
.auth-brand-orbit-d { bottom: 14px; right: 24px; }

.auth-brand-flow {
  inset: auto 20px 10px;
  gap: 8px;
}

.auth-brand-flow span {
  width: min(14vw, 106px);
  height: 3px;
}

.auth-highlight-grid-compact {
  grid-template-columns: minmax(0, 1.25fr) repeat(2, minmax(160px, 1fr));
  align-items: stretch;
}

.auth-highlight-grid-compact .auth-highlight-card-featured {
  gap: 8px;
}

.auth-highlight-grid-compact .auth-highlight-card-featured .auth-highlight-tags {
  display: none;
}

.auth-quick-card {
  gap: 4px;
  justify-content: center;
}

.auth-quick-card strong {
  font-size: 0.94rem;
  line-height: 1.18;
}

.auth-quick-card span {
  font-size: 0.8rem;
  line-height: 1.28;
}

@media (max-width: 1400px) {
  .auth-highlight-grid-compact {
    grid-template-columns: 1fr 1fr;
  }
}

.auth-layout-dark {
  min-height: calc(100vh - 32px);
  grid-template-columns: minmax(0, 1.18fr) minmax(500px, 1fr);
  gap: 36px;
  align-items: start;
}

.auth-hero-classic {
  min-height: 0;
  padding: 28px 18px 28px 12px;
  background: transparent;
  border: 0;
  box-shadow: none;
  backdrop-filter: none;
  gap: 18px;
}

.auth-classic-kicker {
  margin: 0;
  color: #57c4ff;
}

.auth-hero-classic h1 {
  margin: 0;
  max-width: 820px;
  font-size: clamp(2.2rem, 4.2vw, 3.55rem);
  line-height: 0.98;
  letter-spacing: -0.055em;
}

.auth-classic-subtitle {
  max-width: 760px;
  margin: 0;
  color: rgba(221, 232, 252, 0.84);
  font-size: 1rem;
  line-height: 1.5;
}

.auth-classic-board {
  position: relative;
  display: grid;
  gap: 14px;
  padding: 14px;
  border-radius: 28px;
  border: 1px solid rgba(125, 177, 255, 0.32);
  background:
    radial-gradient(circle at 10% 18%, rgba(84, 230, 255, 0.06), transparent 24%),
    radial-gradient(circle at 85% 14%, rgba(141, 103, 255, 0.12), transparent 28%),
    linear-gradient(180deg, rgba(19, 28, 62, 0.94), rgba(11, 17, 39, 0.96));
  box-shadow:
    inset 0 0 0 1px rgba(205, 226, 255, 0.06),
    0 24px 60px rgba(14, 20, 46, 0.42);
}

.auth-classic-board-top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
}

.auth-classic-brand,
.auth-classic-footer-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  padding: 12px 14px;
  border-radius: 18px;
  border: 1px solid rgba(123, 168, 255, 0.18);
  background: rgba(20, 29, 61, 0.86);
}

.auth-classic-brand-mark,
.auth-classic-footer-mark {
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background:
    linear-gradient(145deg, rgba(80, 194, 255, 0.24), rgba(123, 103, 255, 0.2));
  border: 1px solid rgba(177, 207, 255, 0.22);
}

.auth-classic-brand-mark img,
.auth-classic-footer-mark img {
  width: 26px;
  height: 26px;
  display: block;
}

.auth-classic-brand-copy,
.auth-classic-footer-brand {
  min-width: 0;
}

.auth-classic-brand-copy {
  display: grid;
  gap: 2px;
}

.auth-classic-brand-copy strong,
.auth-classic-footer-brand strong {
  color: #7ed8ff;
  font: 700 1rem "Space Grotesk", sans-serif;
}

.auth-classic-brand-copy span,
.auth-classic-footer-brand span {
  color: rgba(226, 235, 255, 0.8);
  font-size: 0.92rem;
  line-height: 1.3;
}

.auth-classic-status-pill {
  align-self: start;
  max-width: 180px;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid rgba(121, 159, 255, 0.16);
  background: rgba(17, 24, 54, 0.72);
  color: rgba(234, 241, 255, 0.86);
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.35;
  text-align: center;
}

.auth-classic-lane-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.auth-classic-lane {
  display: grid;
  gap: 12px;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid rgba(140, 176, 255, 0.16);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.auth-classic-lane-outbound {
  background: linear-gradient(180deg, rgba(28, 47, 103, 0.92), rgba(20, 32, 73, 0.95));
}

.auth-classic-lane-content {
  background: linear-gradient(180deg, rgba(75, 37, 111, 0.94), rgba(48, 24, 77, 0.96));
}

.auth-classic-lane-control {
  background: linear-gradient(180deg, rgba(37, 78, 122, 0.94), rgba(22, 47, 79, 0.96));
}

.auth-classic-lane-label {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  border: 1px solid rgba(196, 214, 255, 0.18);
  color: rgba(237, 243, 255, 0.96);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.auth-classic-lane strong {
  color: #ffffff;
  font: 700 1.24rem "Space Grotesk", sans-serif;
  line-height: 1.15;
}

.auth-classic-lane p {
  margin: 0;
  color: rgba(224, 233, 252, 0.78);
  font-size: 0.92rem;
  line-height: 1.48;
}

.auth-classic-board-footer {
  display: grid;
  gap: 12px;
}

.auth-classic-footer-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  padding: 12px 16px;
  border-radius: 16px;
  border: 1px solid rgba(124, 170, 255, 0.16);
  background: rgba(15, 23, 50, 0.72);
}

.auth-classic-footer-chips span {
  position: relative;
  color: rgba(226, 235, 255, 0.86);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.auth-classic-footer-chips span:not(:last-child)::after {
  content: "•";
  margin-left: 10px;
  color: rgba(110, 195, 255, 0.72);
}

.auth-classic-footer-brand {
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr);
  align-items: center;
}

.auth-entry-card-classic {
  padding: 24px 24px 20px;
  border-radius: 28px;
  background:
    radial-gradient(circle at top right, rgba(141, 103, 255, 0.1), transparent 28%),
    linear-gradient(180deg, rgba(19, 23, 52, 0.95), rgba(11, 16, 36, 0.98));
  border: 1px solid rgba(136, 166, 255, 0.18);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.03),
    0 30px 64px rgba(10, 14, 35, 0.44);
}

.auth-entry-card-classic .auth-entry-heading {
  margin: 0;
  font-size: clamp(1.95rem, 2.4vw, 2.55rem);
  line-height: 1.02;
  letter-spacing: -0.05em;
  display: flex;
  align-items: baseline;
  gap: 0.16em;
  flex-wrap: nowrap;
  white-space: nowrap;
  max-width: none;
}

.auth-entry-card-classic .helper-text {
  margin: 0;
  color: rgba(214, 223, 246, 0.74);
  font-size: 0.94rem;
  line-height: 1.5;
  white-space: nowrap;
  max-width: none;
}

.auth-entry-card-classic .auth-form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  align-items: stretch;
}

.auth-entry-card-classic .field {
  gap: 6px;
}

.auth-entry-card-classic .field span {
  color: rgba(232, 239, 255, 0.84);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.auth-entry-card-classic input {
  min-height: 54px;
  border-radius: 14px;
  background: rgba(17, 22, 52, 0.9);
  border: 1px solid rgba(131, 157, 241, 0.16);
}

.auth-entry-card-classic .primary-button {
  min-height: 54px;
  border-radius: 16px;
  background: linear-gradient(90deg, #80d2ff, #8f98ff 46%, #cc6dff);
  color: #ffffff;
  box-shadow: 0 16px 34px rgba(126, 133, 255, 0.26);
}

.auth-entry-card-classic .secondary-button {
  min-height: 48px;
  border-radius: 14px;
}

.auth-entry-card-classic .primary-button,
.auth-entry-card-classic .auth-divider,
.auth-entry-card-classic .error-text,
.auth-entry-card-classic .full-button {
  grid-column: 1 / -1;
}

.auth-entry-card-classic .auth-divider {
  margin-top: 2px;
}

.auth-entry-card-classic .auth-divider span {
  color: rgba(194, 206, 233, 0.72);
}

.auth-stack {
  width: min(520px, 100%);
}

.auth-meshline-wordmark {
  display: inline-block;
  color: #7ed8ff;
  font: 700 0.98em "Space Grotesk", sans-serif;
  letter-spacing: -0.045em;
  text-shadow: 0 10px 24px rgba(30, 90, 146, 0.24);
}

.auth-entry-heading .auth-meshline-wordmark {
  background: none !important;
  -webkit-background-clip: initial !important;
  background-clip: initial !important;
  -webkit-text-fill-color: #7ed8ff !important;
  color: #7ed8ff !important;
  font-family: "Space Grotesk", sans-serif !important;
  font-weight: 700 !important;
  letter-spacing: -0.05em !important;
  text-shadow: 0 10px 24px rgba(30, 90, 146, 0.24);
}

.auth-layout-dark .auth-stack {
  align-self: start;
  margin-top: 201px;
}

@media (max-width: 1180px) {
  .auth-layout-dark {
    grid-template-columns: 1fr;
    gap: 24px;
    align-items: center;
  }

  .auth-layout-dark .auth-stack {
    width: min(460px, 100%);
    margin-top: 0;
  }

  .auth-hero-classic {
    padding-right: 0;
  }

  .auth-classic-lane-grid {
    grid-template-columns: 1fr;
  }

  .auth-entry-card-classic .auth-form-grid {
    grid-template-columns: 1fr;
  }

  .auth-entry-card-classic .auth-entry-heading,
  .auth-entry-card-classic .helper-text {
    white-space: normal;
  }
}

@media (max-width: 760px) {
  .auth-hero-classic {
    padding: 10px 0 0;
  }

  .auth-hero-classic h1 {
    font-size: 2.25rem;
  }

  .auth-classic-board {
    padding: 12px;
    border-radius: 22px;
  }

  .auth-classic-board-top {
    grid-template-columns: 1fr;
  }

  .auth-classic-status-pill {
    max-width: none;
  }

  .auth-classic-footer-brand {
    grid-template-columns: auto 1fr;
  }

  .auth-classic-footer-brand span {
    grid-column: 1 / -1;
  }

  .auth-entry-card-classic {
    padding: 22px 18px 18px;
  }
}

/* Sidebar rail cleanup: give the collapse control its own lane between brand and nav */
.workspace-sidebar {
  gap: 14px;
}

.workspace-brand-card {
  grid-template-columns: 52px minmax(0, 1fr);
  min-height: 94px;
  align-items: center;
  position: relative;
  padding: 12px 14px;
  gap: 12px;
}

.workspace-brand-copy {
  display: grid;
  gap: 3px;
  min-width: 0;
  align-content: center;
}

.workspace-brand-copy h2 {
  font-size: 1.1rem;
  line-height: 1.02;
  display: block;
}

.workspace-brand-copy small {
  font-size: 0.76rem;
  color: rgba(216, 225, 244, 0.88);
  line-height: 1.14;
  display: block;
  white-space: nowrap;
}

.workspace-brand-tagline {
  display: block;
  white-space: nowrap;
  font-size: 0.62rem;
  line-height: 1.16;
  max-width: none;
  color: rgba(234, 240, 255, 0.84);
}

.workspace-brand-line {
  display: block;
}

.workspace-brand-copy {
  display: grid;
  grid-auto-flow: row;
  align-content: center;
}

.workspace-brand-copy h2,
.workspace-brand-copy small,
.workspace-brand-tagline {
  display: block;
}

.workspace-nav {
  margin-top: 2px;
  padding: 10px 9px;
}

.workspace-nav-button {
  min-height: 52px;
}

/* Marketing workspace cleanup: compact side rail, center review flow, tighter copy */
.agent-workspace-shell {
  grid-template-columns: 196px minmax(0, 1fr) 326px;
}

.agent-operations-shell {
  display: grid;
  grid-template-columns: minmax(0, 0.72fr) minmax(0, 1.28fr);
  gap: 12px;
  min-height: 0;
}

.agent-center-stage,
.agent-output-rail {
  align-content: start;
}

.agent-review-panel {
  grid-template-rows: max-content minmax(0, 1fr);
}

.agent-side-panel,
.agent-workflow-panel {
  align-content: start;
}

.agent-module-overview-compact {
  display: grid;
  gap: 16px;
  padding: 20px 22px;
}

.agent-command-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 320px);
  gap: 16px;
  align-items: start;
}

.agent-command-status {
  gap: 8px;
  padding: 16px 18px;
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(49, 61, 109, 0.88), rgba(26, 33, 63, 0.96)),
    rgba(255, 255, 255, 0.03);
  box-shadow: inset 0 0 0 1px rgba(171, 189, 255, 0.1);
}

.agent-workflow-step-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.agent-workflow-step-card {
  display: grid;
  gap: 6px;
  padding: 14px 14px 15px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.035);
  box-shadow: inset 0 0 0 1px rgba(165, 183, 255, 0.08);
}

.agent-workflow-step-card span {
  color: rgba(182, 195, 232, 0.76);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.agent-workflow-step-card strong {
  color: #ffffff;
  font: 700 1.02rem "Space Grotesk", sans-serif;
}

.agent-workflow-step-card small {
  color: rgba(208, 217, 241, 0.8);
  line-height: 1.42;
}

.agent-workflow-step-card[data-tone="positive"] {
  background:
    linear-gradient(180deg, rgba(38, 72, 101, 0.8), rgba(24, 37, 66, 0.96)),
    rgba(255, 255, 255, 0.03);
}

.agent-workflow-step-card[data-tone="warning"] {
  background:
    linear-gradient(180deg, rgba(78, 36, 52, 0.9), rgba(34, 18, 32, 0.98)),
    rgba(255, 255, 255, 0.03);
  box-shadow: inset 0 0 0 1px rgba(255, 126, 158, 0.16);
}

.agent-workflow-step-card.active {
  box-shadow:
    inset 0 0 0 1px rgba(124, 214, 255, 0.22),
    0 14px 32px rgba(16, 26, 56, 0.28);
  transform: translateY(-1px);
}

.agent-command-actions {
  display: grid;
  gap: 10px;
}

.agent-command-actions-main {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.marketing-panel-head {
  align-items: center;
}

.marketing-panel-summary {
  margin: 6px 0 0;
  max-width: 52ch;
}

.marketing-panel-head-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.agent-command-actions .primary-button,
.agent-queue-empty-actions .primary-button,
.marketing-panel-head-actions .primary-button,
.marketing-review-actions .primary-button,
.output-review-actions-inline .primary-button {
  box-shadow: 0 12px 22px rgba(57, 90, 255, 0.11);
}

.agent-command-actions .primary-button,
.agent-command-actions .secondary-button,
.agent-queue-empty-actions .primary-button,
.agent-queue-empty-actions .secondary-button {
  min-height: 44px;
}

.agent-workflow-panel {
  gap: 14px;
}

#agentScreen.marketing-minimal-mode .workspace-header {
  grid-template-columns: minmax(0, 1fr) max-content;
}

#agentScreen.marketing-minimal-mode .workspace-utility-strip,
#agentScreen.marketing-minimal-mode #workspaceNewProjectButtonAgent,
#agentScreen.marketing-minimal-mode #openAdminButtonSecondary,
#agentScreen.marketing-minimal-mode .workspace-sidebar-section {
  display: none;
}

#agentScreen.marketing-minimal-mode .workspace-main {
  gap: 14px;
  overflow: hidden;
}

#agentScreen.marketing-minimal-mode .agent-workspace-shell[data-layout="marketing-minimal"] {
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 18px;
  align-items: start;
  min-height: 0;
}

#agentScreen.marketing-minimal-mode .agent-center-stage,
#agentScreen.marketing-minimal-mode .agent-output-rail,
#agentScreen.marketing-minimal-mode .agent-side-rail {
  display: grid;
  gap: 18px;
  align-content: start;
  min-height: 0;
  max-height: none;
  overflow: visible;
  padding-right: 0;
}

#agentScreen.marketing-minimal-mode .agent-side-rail {
  display: none;
}

#agentScreen.marketing-minimal-mode .agent-operations-shell {
  grid-template-columns: 1fr;
  gap: 18px;
}

#agentScreen.marketing-minimal-mode .agent-review-panel {
  order: 3;
  background:
    radial-gradient(circle at top left, rgba(74, 206, 255, 0.14), transparent 30%),
    radial-gradient(circle at top right, rgba(166, 104, 255, 0.16), transparent 34%),
    linear-gradient(180deg, rgba(23, 30, 61, 0.98), rgba(11, 16, 37, 0.99));
  border-color: rgba(150, 206, 255, 0.16);
  overflow: hidden;
}

#agentScreen.marketing-minimal-mode .agent-queue-panel {
  order: 2;
  background:
    radial-gradient(circle at top right, rgba(108, 91, 201, 0.1), transparent 30%),
    linear-gradient(180deg, rgba(16, 20, 44, 0.98), rgba(8, 11, 25, 0.99));
  border-color: rgba(124, 151, 220, 0.12);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.03),
    0 22px 46px rgba(5, 8, 18, 0.18);
  overflow: hidden;
}

#agentScreen.marketing-minimal-mode .agent-review-panel,
#agentScreen.marketing-minimal-mode .agent-queue-panel,
#agentScreen.marketing-minimal-mode .agent-workflow-panel {
  border-radius: 28px;
  background:
    radial-gradient(circle at top right, rgba(136, 101, 255, 0.16), transparent 34%),
    radial-gradient(circle at bottom left, rgba(72, 194, 255, 0.12), transparent 28%),
    linear-gradient(180deg, rgba(21, 27, 56, 0.96), rgba(10, 15, 35, 0.98));
  border: 1px solid rgba(170, 193, 255, 0.12);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 26px 60px rgba(6, 10, 24, 0.22);
  overflow: hidden;
}

.marketing-minimal-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 18px;
  align-items: center;
  padding: 24px 26px;
  border-radius: 30px;
  border: 1px solid rgba(176, 203, 255, 0.14);
  background:
    radial-gradient(circle at 100% 0%, rgba(185, 91, 255, 0.24), transparent 30%),
    radial-gradient(circle at 0% 100%, rgba(72, 194, 255, 0.18), transparent 30%),
    linear-gradient(145deg, rgba(31, 41, 84, 0.98), rgba(11, 16, 37, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 30px 70px rgba(8, 12, 27, 0.24);
}

#agentScreen.marketing-minimal-mode #agentProjectBrowserPanel {
  display: none;
}

#agentScreen.marketing-minimal-mode #agentCadencePanel {
  position: sticky;
  top: 0;
  gap: 12px;
  align-content: start;
  padding: 14px;
  border-radius: 22px;
  background:
    radial-gradient(circle at top left, rgba(88, 204, 255, 0.14), transparent 30%),
    linear-gradient(180deg, rgba(22, 28, 54, 0.98), rgba(9, 14, 30, 0.99));
  border: 1px solid rgba(164, 190, 255, 0.12);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 26px 56px rgba(7, 11, 24, 0.22);
}

#agentScreen.marketing-minimal-mode #agentCadencePanel .agent-plan-summary {
  min-height: 112px;
  align-content: start;
  padding: 14px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(44, 42, 82, 0.98), rgba(25, 27, 54, 0.98));
  box-shadow: inset 0 0 0 1px rgba(170, 193, 255, 0.08);
}

#agentScreen.marketing-minimal-mode #agentCadencePanel .agent-cadence-actions {
  display: grid;
  gap: 12px;
}

#agentScreen.marketing-minimal-mode #agentCadencePanel .agent-cadence-actions .secondary-button {
  width: fit-content;
}

.marketing-minimal-hero-copy h3 {
  margin: 0;
  color: #ffffff;
  font-size: clamp(1.35rem, 2.1vw, 1.9rem);
  letter-spacing: -0.03em;
}

.marketing-minimal-hero-copy .helper-text {
  margin-top: 6px;
  max-width: 58ch;
  font-size: 0.9rem;
  line-height: 1.42;
}

.marketing-minimal-hero-meta {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.marketing-minimal-hero-stat {
  min-width: 0;
  padding: 10px 12px;
  border-radius: 14px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.035));
  box-shadow:
    inset 0 0 0 1px rgba(183, 206, 255, 0.12),
    0 16px 28px rgba(6, 10, 24, 0.12);
  backdrop-filter: blur(12px);
}

.marketing-minimal-hero-stat small {
  display: block;
  color: rgba(182, 196, 230, 0.76);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.marketing-minimal-hero-stat strong {
  display: block;
  margin-top: 5px;
  color: #ffffff;
  font: 700 0.96rem "Space Grotesk", sans-serif;
}

.marketing-minimal-hero-actions {
  display: grid;
  gap: 8px;
  justify-items: end;
}

.marketing-minimal-hero-actions .secondary-button {
  min-height: 38px;
  min-width: 144px;
  font-size: 0.84rem;
}

.marketing-minimal-hero-actions .primary-button {
  min-height: 44px;
  min-width: 144px;
  font-size: 0.9rem;
  background: linear-gradient(135deg, rgba(86, 155, 255, 0.82), rgba(124, 92, 255, 0.82));
  box-shadow:
    0 16px 28px rgba(74, 95, 255, 0.17),
    inset 0 1px 0 rgba(255, 255, 255, 0.14);
}

.marketing-frequency-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(176, 203, 255, 0.12);
  background:
    radial-gradient(circle at top right, rgba(78, 200, 255, 0.14), transparent 34%),
    linear-gradient(180deg, rgba(25, 34, 69, 0.96), rgba(13, 18, 39, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 18px 42px rgba(8, 12, 24, 0.18);
}

.marketing-frequency-card-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 12px;
  align-items: start;
}

.marketing-frequency-card-head small {
  display: block;
  color: rgba(180, 193, 229, 0.72);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.marketing-frequency-card-head strong {
  display: block;
  margin-top: 6px;
  color: #ffffff;
  font: 700 1rem "Space Grotesk", sans-serif;
}

.marketing-frequency-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.marketing-frequency-stat {
  display: grid;
  gap: 6px;
  min-width: 0;
  padding: 10px 11px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
  box-shadow: inset 0 0 0 1px rgba(176, 203, 255, 0.08);
}

.marketing-frequency-stat.live {
  background:
    radial-gradient(circle at top right, rgba(90, 220, 175, 0.14), transparent 38%),
    rgba(255, 255, 255, 0.035);
}

.marketing-frequency-stat.warning {
  background:
    radial-gradient(circle at top right, rgba(255, 138, 159, 0.16), transparent 38%),
    rgba(255, 255, 255, 0.035);
  box-shadow: inset 0 0 0 1px rgba(255, 140, 170, 0.12);
}

.marketing-frequency-stat small {
  color: rgba(182, 196, 230, 0.76);
  font-size: 0.66rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.marketing-frequency-stat strong {
  color: #ffffff;
  font: 700 0.9rem "Space Grotesk", sans-serif;
  overflow-wrap: anywhere;
}

.marketing-frequency-presets {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.marketing-frequency-preset {
  appearance: none;
  border: 0;
  cursor: pointer;
  display: grid;
  gap: 6px;
  justify-items: start;
  min-width: 0;
  padding: 10px 12px;
  border-radius: 14px;
  color: #edf3ff;
  text-align: left;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.028));
  box-shadow:
    inset 0 0 0 1px rgba(176, 203, 255, 0.1),
    0 14px 28px rgba(7, 11, 22, 0.12);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease, background 180ms ease;
}

.marketing-frequency-preset:hover {
  transform: translateY(-1px);
  box-shadow:
    inset 0 0 0 1px rgba(182, 214, 255, 0.16),
    0 18px 34px rgba(8, 12, 24, 0.16);
}

.marketing-frequency-preset.active {
  background:
    radial-gradient(circle at top right, rgba(95, 213, 255, 0.18), transparent 38%),
    radial-gradient(circle at bottom left, rgba(166, 104, 255, 0.18), transparent 30%),
    linear-gradient(160deg, rgba(46, 63, 123, 0.98), rgba(20, 28, 58, 0.98));
  box-shadow:
    inset 0 0 0 1px rgba(146, 218, 255, 0.24),
    0 20px 40px rgba(18, 29, 65, 0.24);
}

.marketing-frequency-preset strong {
  color: #ffffff;
  font: 700 0.9rem "Space Grotesk", sans-serif;
}

.marketing-frequency-preset small {
  color: rgba(210, 222, 248, 0.78);
  line-height: 1.32;
  font-size: 0.78rem;
}

.marketing-frequency-input input {
  min-height: 50px;
}

.agent-setup-guide {
  display: grid;
  gap: 12px;
}

.agent-setup-overview-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border-radius: 18px;
  background:
    radial-gradient(circle at top right, rgba(95, 212, 255, 0.14), transparent 34%),
    linear-gradient(180deg, rgba(31, 41, 84, 0.96), rgba(15, 20, 43, 0.98));
  box-shadow:
    inset 0 0 0 1px rgba(176, 203, 255, 0.1),
    0 22px 46px rgba(8, 12, 24, 0.18);
}

.agent-setup-overview-card.compact {
  gap: 12px;
  padding: 16px;
}

.agent-setup-overview-card.is-blocked {
  background:
    radial-gradient(circle at top right, rgba(255, 114, 151, 0.16), transparent 34%),
    linear-gradient(180deg, rgba(61, 31, 52, 0.96), rgba(21, 14, 28, 0.98));
  box-shadow:
    inset 0 0 0 1px rgba(255, 140, 170, 0.14),
    0 24px 48px rgba(28, 11, 19, 0.22);
}

.agent-setup-overview-copy {
  display: grid;
  gap: 10px;
}

.agent-setup-overview-copy strong {
  color: #ffffff;
  font: 700 1.14rem "Space Grotesk", sans-serif;
}

.agent-setup-overview-copy p {
  margin: 0;
  color: rgba(214, 224, 246, 0.82);
  line-height: 1.5;
}

.agent-setup-overview-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.agent-setup-overview-stats div {
  min-width: 0;
  padding: 12px 13px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  box-shadow: inset 0 0 0 1px rgba(176, 203, 255, 0.08);
}

.agent-setup-overview-stats small {
  display: block;
  color: rgba(182, 196, 230, 0.76);
  font-size: 0.66rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.agent-setup-overview-stats strong {
  display: block;
  margin-top: 6px;
  color: #ffffff;
  font: 700 1rem "Space Grotesk", sans-serif;
}

.agent-setup-guide-grid {
  display: grid;
  gap: 12px;
}

.agent-setup-guide-grid.compact {
  gap: 10px;
}

.agent-setup-guide-card.compact {
  padding: 14px;
  gap: 10px;
}

.agent-setup-guide-head.compact {
  gap: 10px;
  align-items: center;
}

.agent-setup-guide-title.compact {
  gap: 10px;
}

.agent-setup-guide-title.compact span {
  color: rgba(210, 220, 246, 0.74);
  line-height: 1.35;
}

.agent-setup-optional {
  display: grid;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.035);
  box-shadow: inset 0 0 0 1px rgba(176, 203, 255, 0.08);
}

.agent-setup-optional summary {
  cursor: pointer;
  color: #eef3ff;
  font: 700 0.94rem "Space Grotesk", sans-serif;
}

.agent-setup-optional summary::-webkit-details-marker {
  display: none;
}

.marketing-active-review-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
  border-radius: 16px;
  background:
    radial-gradient(circle at top right, rgba(95, 212, 255, 0.12), transparent 34%),
    linear-gradient(180deg, rgba(33, 43, 85, 0.94), rgba(16, 22, 46, 0.98));
  box-shadow:
    inset 0 0 0 1px rgba(176, 203, 255, 0.1),
    0 10px 18px rgba(8, 12, 24, 0.1);
}

.marketing-active-review-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.marketing-active-review-copy strong {
  color: #ffffff;
  font: 700 0.92rem "Space Grotesk", sans-serif;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.marketing-active-review-copy p {
  margin: 0;
  color: rgba(210, 220, 246, 0.78);
  line-height: 1.35;
  font-size: 0.84rem;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
  overflow: hidden;
}

.marketing-active-review-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.marketing-active-review-actions .secondary-button,
.marketing-active-review-actions .primary-button {
  min-height: 36px;
  min-width: 0;
  padding: 0 12px;
  font-size: 0.84rem;
}

.marketing-publish-success-bar,
.marketing-selection-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 14px;
  align-items: center;
  margin-bottom: 14px;
  padding: 14px 16px;
  border-radius: 18px;
  background:
    radial-gradient(circle at top right, rgba(86, 233, 173, 0.16), transparent 36%),
    linear-gradient(180deg, rgba(23, 49, 55, 0.96), rgba(12, 26, 32, 0.98));
  box-shadow:
    inset 0 0 0 1px rgba(120, 233, 184, 0.14),
    0 18px 34px rgba(7, 18, 18, 0.18);
}

.marketing-publish-success-copy,
.marketing-publish-success-actions {
  display: grid;
  gap: 8px;
}

.marketing-publish-success-copy strong {
  color: #ffffff;
  font: 700 1rem "Space Grotesk", sans-serif;
}

.marketing-publish-success-copy p {
  margin: 0;
  color: rgba(214, 235, 230, 0.8);
}

.marketing-publish-success-actions {
  grid-auto-flow: column;
  grid-auto-columns: max-content;
  align-items: center;
}

.marketing-selection-bar {
  background:
    radial-gradient(circle at top right, rgba(255, 192, 96, 0.16), transparent 36%),
    linear-gradient(180deg, rgba(52, 42, 25, 0.96), rgba(24, 18, 10, 0.98));
  box-shadow:
    inset 0 0 0 1px rgba(255, 209, 128, 0.14),
    0 18px 34px rgba(25, 16, 8, 0.18);
}

#agentScreen.marketing-minimal-mode .agent-workflow-panel {
  padding: 22px;
}

#agentScreen.marketing-minimal-mode .agent-detail-sections {
  gap: 12px;
}

#agentScreen.marketing-minimal-mode .agent-detail-block,
#agentScreen.marketing-minimal-mode .agent-auth-summary {
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(33, 40, 78, 0.9), rgba(16, 21, 44, 0.96));
  box-shadow: inset 0 0 0 1px rgba(176, 203, 255, 0.08);
}

.agent-setup-guide-card {
  display: grid;
  gap: 10px;
  padding: 12px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.035);
  box-shadow: inset 0 0 0 1px rgba(165, 183, 255, 0.08);
}

.agent-setup-guide-card[data-tone="positive"] {
  background:
    linear-gradient(180deg, rgba(34, 63, 94, 0.84), rgba(23, 34, 61, 0.98)),
    rgba(255, 255, 255, 0.03);
}

.agent-setup-guide-card[data-tone="warning"] {
  background:
    linear-gradient(180deg, rgba(78, 36, 52, 0.94), rgba(34, 18, 32, 0.98)),
    rgba(255, 255, 255, 0.03);
  box-shadow:
    inset 0 0 0 1px rgba(255, 126, 158, 0.2),
    0 16px 34px rgba(44, 16, 28, 0.26);
}

#agentScreen.marketing-minimal-mode .agent-setup-guide-card {
  border-radius: 22px;
}

.agent-setup-guide-head {
  display: grid;
  gap: 12px;
}

.agent-setup-guide-title {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.agent-setup-guide-title strong {
  display: block;
  margin-bottom: 4px;
  color: #ffffff;
}

.agent-setup-guide-title span:last-child {
  color: rgba(208, 217, 241, 0.8);
  line-height: 1.32;
  font-size: 0.84rem;
}

.agent-setup-guide-step {
  display: inline-flex;
  width: 30px;
  height: 30px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(104, 154, 255, 0.16);
  color: #dce5ff;
  font: 700 0.86rem "Space Grotesk", sans-serif;
}

.agent-setup-guide-status {
  display: grid;
  gap: 6px;
  justify-items: start;
}

.agent-setup-guide-meta {
  display: grid;
  gap: 6px;
}

.agent-setup-guide-kind {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: rgba(226, 234, 255, 0.84);
  font-size: 0.72rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.agent-setup-guide-account {
  color: rgba(210, 220, 246, 0.82);
  line-height: 1.45;
}

.agent-setup-guide-status small {
  color: rgba(228, 232, 247, 0.78);
  line-height: 1.35;
}

.pill.warning {
  background: rgba(255, 111, 145, 0.12);
  color: #ffb3c5;
  border-color: rgba(255, 111, 145, 0.22);
}

.marketing-run-card,
.marketing-review-card {
  position: relative;
  overflow: visible;
  border-radius: 22px;
  border: 1px solid rgba(176, 203, 255, 0.14);
  background:
    radial-gradient(circle at 92% 50%, rgba(198, 104, 255, 0.14), transparent 28%),
    radial-gradient(circle at 8% 24%, rgba(101, 201, 255, 0.12), transparent 24%),
    linear-gradient(180deg, rgba(36, 44, 83, 0.96), rgba(16, 22, 46, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 20px 44px rgba(9, 13, 28, 0.18);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.marketing-run-card.primary,
.marketing-review-card.active {
  border-color: rgba(154, 210, 255, 0.28);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 22px 48px rgba(10, 15, 34, 0.24),
    0 0 0 1px rgba(118, 204, 255, 0.08);
}

.marketing-review-card:hover,
.marketing-run-card:hover {
  transform: translateY(-2px);
  border-color: rgba(168, 214, 255, 0.24);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 24px 52px rgba(8, 12, 28, 0.22);
}

.marketing-run-card {
  display: grid;
  gap: 12px;
  padding: 18px;
}

.marketing-run-accordion {
  padding: 0;
  overflow: hidden;
}

.marketing-run-summary {
  list-style: none;
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content max-content;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
  cursor: pointer;
}

.marketing-run-summary::-webkit-details-marker {
  display: none;
}

.marketing-run-summary-main,
.marketing-run-summary-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.marketing-run-summary-main strong {
  min-width: 0;
  color: #ffffff;
  font: 700 0.95rem "Space Grotesk", sans-serif;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.marketing-run-summary-meta {
  color: rgba(202, 214, 242, 0.74);
  font-size: 0.78rem;
  justify-content: flex-end;
  flex-wrap: wrap;
}

.marketing-run-summary-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.compact-run-action {
  min-height: 34px;
  padding: 0 12px;
  font-size: 0.76rem;
}

.marketing-run-details {
  display: grid;
  gap: 10px;
  padding: 0 14px 12px;
}

.marketing-run-card-top,
.marketing-review-card-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 16px;
  align-items: start;
}

.marketing-run-card-copy,
.marketing-review-card-copy,
.marketing-review-card-title {
  min-width: 0;
}

.marketing-run-card-copy strong,
.marketing-review-card-title strong {
  display: block;
  color: #ffffff;
  font: 700 1.08rem "Space Grotesk", sans-serif;
}

.marketing-run-card-copy p,
.marketing-review-card-title p {
  margin: 6px 0 0;
  color: rgba(212, 222, 246, 0.82);
  line-height: 1.45;
}

.marketing-run-card-meta,
.marketing-review-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  color: rgba(202, 214, 242, 0.78);
  font-size: 0.82rem;
}

.marketing-run-card-progress {
  display: grid;
  justify-items: end;
  gap: 6px;
  min-width: 118px;
}

.marketing-run-card-progress strong {
  color: #ffffff;
  font: 700 1.2rem "Space Grotesk", sans-serif;
}

.marketing-run-card-progress span {
  color: rgba(202, 214, 242, 0.72);
  font-size: 0.8rem;
  text-align: right;
}

.marketing-run-progress {
  display: grid;
  gap: 8px;
}

.marketing-run-stage {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  box-shadow: inset 0 0 0 1px rgba(167, 185, 255, 0.08);
}

.marketing-run-stage-label {
  color: rgba(174, 189, 224, 0.76);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.68rem;
}

.marketing-run-stage strong {
  color: #ffffff;
  font: 700 0.94rem "Space Grotesk", sans-serif;
}

.marketing-run-progress-track {
  height: 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
  box-shadow: inset 0 0 0 1px rgba(159, 181, 255, 0.08);
}

.marketing-run-progress-track span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(86, 215, 255, 0.98), rgba(114, 141, 255, 0.98), rgba(212, 104, 255, 0.98));
  box-shadow: 0 0 24px rgba(157, 114, 255, 0.34);
}

.marketing-run-progress-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: rgba(207, 217, 242, 0.8);
  font-size: 0.82rem;
}

.marketing-run-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.marketing-run-metric,
.marketing-review-fact {
  min-width: 0;
  padding: 11px 12px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.042);
  box-shadow: inset 0 0 0 1px rgba(165, 183, 255, 0.08);
}

.marketing-run-metric span,
.marketing-review-fact small {
  display: block;
  color: rgba(176, 190, 224, 0.78);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.marketing-run-metric strong,
.marketing-review-fact strong {
  display: block;
  margin-top: 6px;
  color: #ffffff;
  overflow-wrap: anywhere;
}

.marketing-run-metric.is-empty {
  grid-column: 1 / -1;
}

.marketing-queue-empty,
.marketing-review-empty {
  display: grid;
  gap: 10px;
  padding: 18px 20px;
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(30, 37, 70, 0.94), rgba(17, 22, 43, 0.98)),
    rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(176, 203, 255, 0.12);
}

.marketing-queue-empty-summary {
  color: rgba(205, 215, 240, 0.76);
  line-height: 1.42;
}

.marketing-review-card {
  padding: 18px 18px 16px;
}

.marketing-review-card-main {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr) max-content;
  gap: 16px;
  align-items: center;
}

.marketing-review-card-visual {
  position: relative;
  display: grid;
  align-content: end;
  gap: 6px;
  min-height: 178px;
  padding: 18px;
  border-radius: 22px;
  overflow: hidden;
  background:
    radial-gradient(circle at 24% 22%, rgba(79, 211, 255, 0.28), transparent 28%),
    radial-gradient(circle at 78% 20%, rgba(191, 95, 255, 0.28), transparent 34%),
    linear-gradient(160deg, rgba(32, 48, 94, 0.98), rgba(16, 20, 42, 0.98));
  box-shadow:
    inset 0 0 0 1px rgba(183, 206, 255, 0.12),
    0 18px 38px rgba(8, 12, 24, 0.2);
}

.marketing-review-card-visual::after {
  content: "";
  position: absolute;
  inset: auto -20% -36% 18%;
  height: 140px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(92, 211, 255, 0.26), transparent 64%);
  filter: blur(10px);
}

.marketing-review-card-visual-orb {
  width: 72px;
  height: 72px;
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.24), rgba(255,255,255,0.08)),
    linear-gradient(135deg, rgba(81, 224, 255, 0.92), rgba(112, 126, 255, 0.92), rgba(192, 96, 255, 0.92));
  box-shadow:
    0 22px 42px rgba(98, 102, 255, 0.3),
    inset 0 1px 0 rgba(255,255,255,0.4);
}

.marketing-review-card-visual span,
.marketing-review-card-visual small {
  position: relative;
  z-index: 1;
  color: rgba(214, 225, 248, 0.78);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.marketing-review-card-visual span {
  margin-top: 12px;
  font-size: 0.72rem;
}

.marketing-review-card-visual strong {
  position: relative;
  z-index: 1;
  color: #ffffff;
  font: 700 1.18rem "Space Grotesk", sans-serif;
}

.marketing-review-card-visual small {
  font-size: 0.72rem;
  overflow-wrap: anywhere;
}

.marketing-review-card-title p {
  max-width: 60ch;
}

.marketing-review-card-meta {
  margin-top: 10px;
}

.marketing-review-card-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.marketing-review-card-readiness {
  display: grid;
  gap: 10px;
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.04);
  box-shadow: inset 0 0 0 1px rgba(165, 183, 255, 0.08);
}

.marketing-review-card-readiness.is-ready {
  background:
    radial-gradient(circle at top right, rgba(79, 214, 163, 0.12), transparent 38%),
    rgba(255, 255, 255, 0.04);
  box-shadow:
    inset 0 0 0 1px rgba(114, 224, 181, 0.12),
    0 10px 24px rgba(10, 20, 28, 0.1);
}

.marketing-review-card-readiness.is-blocked {
  background:
    radial-gradient(circle at top right, rgba(255, 120, 120, 0.14), transparent 38%),
    rgba(255, 255, 255, 0.04);
  box-shadow:
    inset 0 0 0 1px rgba(255, 142, 142, 0.12),
    0 10px 24px rgba(22, 12, 24, 0.14);
}

.marketing-review-card-readiness p {
  margin: 0;
  color: rgba(214, 224, 246, 0.82);
  line-height: 1.5;
}

.marketing-review-blockers {
  margin: 0;
  padding-left: 18px;
  color: rgba(228, 236, 255, 0.88);
  display: grid;
  gap: 6px;
}

.marketing-review-blockers li {
  line-height: 1.45;
}

.marketing-review-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(132px, max-content));
  gap: 10px;
  justify-content: end;
}

.marketing-review-actions button {
  min-height: 46px;
  min-width: 0;
}

.marketing-edit-button {
  background: rgba(255, 255, 255, 0.045);
}

.marketing-run-row {
  gap: 8px;
  padding: 12px 14px;
  border-radius: 16px;
}

.marketing-run-row-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 14px;
  align-items: center;
}

.marketing-run-row-progress-value {
  color: #ffffff;
  font: 700 0.9rem "Space Grotesk", sans-serif;
}

.marketing-run-progress.compact {
  margin-top: 2px;
}

.marketing-run-stage-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.marketing-run-stage-pill {
  padding: 4px 8px;
  border-radius: 999px;
  color: rgba(195, 208, 236, 0.74);
  font-size: 0.66rem;
  background: rgba(255, 255, 255, 0.04);
  box-shadow: inset 0 0 0 1px rgba(176, 203, 255, 0.08);
}

.marketing-run-stage-pill.done {
  color: rgba(173, 225, 203, 0.88);
  background: rgba(89, 214, 163, 0.08);
}

.marketing-run-stage-pill.active {
  color: #ffffff;
  background:
    radial-gradient(circle at top right, rgba(95, 212, 255, 0.16), transparent 34%),
    linear-gradient(180deg, rgba(45, 57, 109, 0.98), rgba(18, 23, 46, 0.98));
  box-shadow: inset 0 0 0 1px rgba(146, 218, 255, 0.2);
}

.marketing-run-row-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px;
  color: rgba(202, 214, 242, 0.72);
  font-size: 0.74rem;
}

#agentScreen.marketing-minimal-mode .agent-queue-panel {
  gap: 10px;
}

#agentScreen.marketing-minimal-mode #agentRunsList {
  max-height: 320px;
}

.marketing-queue-empty.compact {
  gap: 10px;
  padding: 18px;
}

.marketing-review-row {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr) max-content;
  gap: 12px;
  align-items: center;
  padding: 10px 12px;
  border-radius: 16px;
  border-color: rgba(166, 206, 255, 0.16);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 10px 18px rgba(8, 12, 26, 0.12);
}

.marketing-review-row.active {
  border-color: rgba(105, 215, 255, 0.26);
  background:
    radial-gradient(circle at top left, rgba(86, 215, 255, 0.08), transparent 28%),
    linear-gradient(180deg, rgba(34, 43, 85, 0.96), rgba(17, 23, 47, 0.98));
  box-shadow:
    inset 0 0 0 1px rgba(127, 220, 255, 0.14),
    0 22px 44px rgba(8, 12, 26, 0.24);
}

.marketing-review-row-accent {
  position: relative;
  display: grid;
  gap: 4px;
  align-content: center;
  min-height: 52px;
  padding: 8px;
  border-radius: 14px;
  overflow: hidden;
  background:
    radial-gradient(circle at top left, rgba(89, 213, 255, 0.24), transparent 34%),
    radial-gradient(circle at bottom right, rgba(176, 95, 255, 0.24), transparent 34%),
    linear-gradient(160deg, rgba(29, 41, 82, 0.98), rgba(12, 17, 37, 0.98));
  box-shadow:
    inset 0 0 0 1px rgba(176, 203, 255, 0.12),
    0 18px 38px rgba(8, 12, 24, 0.18);
}

.marketing-review-row-accent::after {
  content: "";
  position: absolute;
  inset: auto -16% -42% 16%;
  height: 120px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(92, 211, 255, 0.24), transparent 66%);
  filter: blur(10px);
}

.marketing-review-row-accent span,
.marketing-review-row-accent strong {
  position: relative;
  z-index: 1;
}

.marketing-review-row-accent span {
  color: rgba(214, 225, 248, 0.78);
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.marketing-review-row-accent strong {
  color: #ffffff;
  font: 700 0.94rem "Space Grotesk", sans-serif;
}

.marketing-review-row-copy {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.marketing-review-row-statuses {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: end;
  align-items: center;
}

.marketing-review-row .marketing-review-card-title strong {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
  overflow: hidden;
  font-size: 1rem;
  line-height: 1.2;
}

.marketing-review-row .marketing-review-card-title p,
.marketing-review-card-readiness.compact p {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
  overflow: hidden;
}

.marketing-review-row .marketing-review-card-title p {
  margin-top: 2px;
  color: rgba(212, 222, 246, 0.76);
  font-size: 0.86rem;
}

.marketing-review-card-meta {
  margin-top: 0;
  color: rgba(194, 207, 236, 0.66);
  font-size: 0.74rem;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.marketing-review-row-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 10px;
  align-items: center;
}

.marketing-readiness-checklist {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.marketing-readiness-checklist.compact {
  gap: 6px;
}

.marketing-readiness-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  color: rgba(207, 218, 243, 0.8);
  font-size: 0.72rem;
  background: rgba(255, 255, 255, 0.045);
  box-shadow: inset 0 0 0 1px rgba(176, 203, 255, 0.08);
}

.marketing-readiness-chip.done {
  color: rgba(191, 244, 219, 0.92);
  background: rgba(80, 208, 154, 0.12);
  box-shadow: inset 0 0 0 1px rgba(112, 232, 178, 0.16);
}

.marketing-readiness-chip-dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: rgba(255, 150, 150, 0.9);
  box-shadow: 0 0 10px rgba(255, 120, 120, 0.22);
}

.marketing-readiness-chip.done .marketing-readiness-chip-dot {
  background: rgba(110, 238, 178, 0.96);
  box-shadow: 0 0 10px rgba(110, 238, 178, 0.24);
}

.marketing-review-actions.compact {
  display: grid;
  grid-template-columns: max-content max-content max-content;
  gap: 8px;
  align-items: center;
  align-self: center;
}

.marketing-review-actions.compact .secondary-button,
.marketing-review-actions.compact .primary-button {
  min-width: 88px;
  min-height: 36px;
  padding-inline: 12px;
  font-size: 0.82rem;
  box-shadow:
    0 10px 16px rgba(10, 14, 30, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.marketing-review-card-facts.compact {
  gap: 8px;
}

.marketing-review-card-facts.compact .marketing-review-fact {
  padding: 9px 10px;
}

.marketing-review-card-facts.compact .marketing-review-fact strong {
  margin-top: 4px;
  font-size: 0.9rem;
}

.marketing-card-menu {
  position: relative;
}

.marketing-card-menu summary {
  list-style: none;
}

.marketing-card-menu summary::-webkit-details-marker {
  display: none;
}

.marketing-card-menu-toggle {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  cursor: pointer;
  color: #eef3ff;
  font: 700 1rem "Space Grotesk", sans-serif;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.03));
  box-shadow:
    inset 0 0 0 1px rgba(176, 203, 255, 0.1),
    0 14px 28px rgba(8, 12, 24, 0.16);
}

.marketing-card-menu[open] .marketing-card-menu-toggle {
  background:
    radial-gradient(circle at top right, rgba(95, 212, 255, 0.18), transparent 34%),
    linear-gradient(180deg, rgba(45, 57, 109, 0.98), rgba(18, 23, 46, 0.98));
}

.marketing-card-menu-list {
  position: absolute;
  bottom: calc(100% + 10px);
  right: 0;
  z-index: 6;
  display: grid;
  gap: 6px;
  min-width: 196px;
  padding: 8px;
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(25, 33, 67, 0.98), rgba(12, 16, 36, 0.98));
  box-shadow:
    inset 0 0 0 1px rgba(176, 203, 255, 0.12),
    0 24px 48px rgba(8, 12, 24, 0.28);
}

#agentScreen.marketing-minimal-mode #agentOutputsList,
#agentScreen.marketing-minimal-mode #agentRunsList {
  overflow: visible;
  padding-right: 0;
}

#agentScreen.marketing-minimal-mode .agent-review-panel,
#agentScreen.marketing-minimal-mode .agent-queue-panel {
  grid-template-rows: max-content max-content;
}

#agentScreen.marketing-minimal-mode #agentOutputsList {
  max-height: none;
}

#agentScreen.marketing-minimal-mode #agentRunsList {
  max-height: none;
}

#agentScreen.marketing-minimal-mode .agent-review-panel {
  gap: 12px;
}

#agentScreen.marketing-minimal-mode .agent-queue-panel {
  gap: 12px;
}

.marketing-frequency-card {
  gap: 12px;
  padding: 16px;
  border-radius: 20px;
}

.marketing-frequency-card-head {
  align-items: center;
}

.marketing-frequency-card-head small {
  font-size: 0.68rem;
}

.marketing-frequency-card-head strong {
  font-size: 1.1rem;
}

.marketing-frequency-stats {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.marketing-frequency-stat {
  padding: 10px 12px;
  border-radius: 14px;
}

.marketing-frequency-presets {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.marketing-frequency-preset {
  min-height: 72px;
}

.agent-setup-guide {
  display: grid;
  gap: 10px;
}

.marketing-auth-quick-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.marketing-auth-quick-button {
  appearance: none;
  border: 0;
  cursor: pointer;
  display: grid;
  gap: 6px;
  text-align: left;
  padding: 14px 16px;
  border-radius: 16px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.05);
  box-shadow: inset 0 0 0 1px rgba(176, 203, 255, 0.1);
}

.marketing-auth-quick-button.is-connected {
  background: rgba(68, 190, 128, 0.12);
  box-shadow: inset 0 0 0 1px rgba(90, 226, 155, 0.24);
}

.marketing-auth-quick-button.is-missing {
  background: rgba(190, 68, 92, 0.12);
  box-shadow: inset 0 0 0 1px rgba(255, 117, 145, 0.2);
}

.marketing-auth-quick-button[data-open-marketing-auth-modal="google"],
.marketing-auth-quick-button[data-open-marketing-auth-modal="meta"] {
  background: rgba(111, 139, 210, 0.1);
  box-shadow: inset 0 0 0 1px rgba(158, 184, 255, 0.16);
}

.marketing-auth-quick-label {
  font: 700 0.95rem "Space Grotesk", sans-serif;
}

.marketing-auth-quick-state {
  font-size: 0.8rem;
  color: rgba(231, 239, 255, 0.84);
}

.marketing-auth-modal-card {
  width: min(720px, calc(100vw - 32px));
  max-height: calc(100vh - 28px);
  overflow: auto;
  display: grid;
  gap: 10px;
  padding: 16px;
}

.marketing-auth-modal-provider-tabs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.marketing-auth-modal-card .panel-head.compact {
  gap: 10px;
}

.marketing-auth-modal-card .panel-head.compact h4 {
  font-size: 1.02rem;
}

.marketing-auth-form {
  gap: 10px;
}

.marketing-auth-save-status-shell.hidden {
  display: none;
}

.marketing-auth-save-status {
  display: grid;
  gap: 8px;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(112, 134, 214, 0.34);
  background: linear-gradient(180deg, rgba(31, 40, 78, 0.92), rgba(20, 27, 56, 0.94));
}

.marketing-auth-save-status.success {
  border-color: rgba(96, 206, 174, 0.36);
  background: linear-gradient(180deg, rgba(23, 57, 71, 0.88), rgba(17, 37, 50, 0.94));
}

.marketing-auth-save-status.warning {
  border-color: rgba(235, 172, 114, 0.34);
  background: linear-gradient(180deg, rgba(64, 45, 40, 0.88), rgba(36, 27, 28, 0.94));
}

.marketing-auth-save-status.error {
  border-color: rgba(238, 116, 160, 0.34);
  background: linear-gradient(180deg, rgba(67, 31, 51, 0.9), rgba(35, 21, 35, 0.95));
}

.marketing-auth-save-status strong {
  color: #f3f7ff;
  font-size: 0.94rem;
}

.marketing-auth-save-status-list {
  margin: 0;
  padding-left: 18px;
  color: rgba(230, 238, 255, 0.86);
  display: grid;
  gap: 4px;
  font-size: 0.79rem;
}

.marketing-auth-save-status-list.warnings {
  color: rgba(255, 214, 186, 0.94);
}

.marketing-auth-provider-copy {
  gap: 6px;
}

.marketing-auth-provider-copy .helper-text {
  font-size: 0.8rem;
  line-height: 1.35;
}

.marketing-auth-provider-actions {
  gap: 6px;
}

.marketing-auth-connect-button.needs-setup {
  background:
    linear-gradient(135deg, rgba(85, 102, 160, 0.92), rgba(96, 83, 168, 0.92));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 12px 22px rgba(52, 62, 115, 0.14);
}

.marketing-auth-connect-button.needs-setup::after {
  content: "Fill client ID + secret";
  display: block;
  margin-top: 2px;
  font-size: 0.66rem;
  font-weight: 500;
  color: rgba(238, 243, 255, 0.82);
}

.marketing-auth-field input {
  min-height: 44px;
}

@media (max-height: 920px) {
  .marketing-auth-modal-card {
    max-height: calc(100vh - 20px);
    gap: 8px;
    padding: 14px;
  }

  .marketing-auth-provider-summary {
    padding: 10px 12px;
  }

  .marketing-auth-field {
    padding: 10px;
  }
}

@media (max-height: 820px) {
  .marketing-auth-fields {
    gap: 6px;
  }

  .marketing-auth-field-footer a {
    font-size: 0.7rem;
  }
}

.marketing-help-popover.hidden {
  display: none;
}

.marketing-review-actions.compact {
  display: flex;
  align-items: center;
  gap: 8px;
  align-self: center;
}

.marketing-review-actions.compact .secondary-button,
.marketing-review-actions.compact .primary-button,
.marketing-card-menu-toggle {
  min-height: 42px;
}

.marketing-card-menu-item {
  appearance: none;
  border: 0;
  cursor: pointer;
  width: 100%;
  min-height: 40px;
  padding: 10px 12px;
  border-radius: 12px;
  text-align: left;
  color: #edf3ff;
  background: rgba(255, 255, 255, 0.04);
  box-shadow: inset 0 0 0 1px rgba(176, 203, 255, 0.08);
}

.marketing-card-menu-item:hover {
  background: rgba(255, 255, 255, 0.08);
}

.marketing-card-menu-item.danger {
  color: #ffd5de;
  background: rgba(255, 101, 132, 0.08);
  box-shadow: inset 0 0 0 1px rgba(255, 118, 145, 0.12);
}

.marketing-run-timeline {
  display: grid;
  gap: 8px;
  margin-top: 4px;
}

.marketing-run-timeline-entry {
  display: grid;
  grid-template-columns: 150px 140px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 8px 10px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.035);
  box-shadow: inset 0 0 0 1px rgba(176, 203, 255, 0.08);
}

.marketing-run-timeline-entry span,
.marketing-run-timeline-entry strong {
  min-width: 0;
  overflow-wrap: anywhere;
}

.marketing-run-timeline-entry span {
  color: rgba(203, 214, 242, 0.76);
  font-size: 0.76rem;
}

.marketing-run-timeline-entry strong {
  color: #f3f7ff;
  font-size: 0.8rem;
}

.marketing-run-detail-actions .secondary-button.danger {
  min-height: 36px;
  padding: 0 14px;
  border-color: rgba(255, 118, 145, 0.3);
  color: #ffd7e1;
  background: rgba(255, 76, 118, 0.08);
  box-shadow: none;
}

.marketing-run-detail-actions .secondary-button.danger:hover {
  background: rgba(255, 76, 118, 0.14);
}

.recent-published-modal-card {
  width: min(1180px, calc(100vw - 24px));
  max-height: calc(100vh - 24px);
  display: grid;
  grid-template-rows: max-content max-content minmax(0, 1fr);
  gap: 16px;
}

.recent-published-summary {
  padding: 14px 16px;
  border-radius: 18px;
  color: rgba(224, 232, 248, 0.86);
  background: rgba(255, 255, 255, 0.04);
  box-shadow: inset 0 0 0 1px rgba(176, 203, 255, 0.08);
}

.recent-published-list {
  display: grid;
  gap: 12px;
  overflow: auto;
  padding-right: 4px;
}

.recent-published-card {
  display: grid;
  gap: 14px;
  padding: 18px;
  border-radius: 22px;
  background:
    radial-gradient(circle at top right, rgba(124, 102, 255, 0.12), transparent 28%),
    linear-gradient(180deg, rgba(18, 24, 50, 0.94), rgba(10, 15, 33, 0.98));
  box-shadow: inset 0 0 0 1px rgba(176, 203, 255, 0.08);
}

.recent-published-card-head,
.recent-published-card-metrics,
.recent-published-card-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.recent-published-card-head {
  justify-content: space-between;
}

.recent-published-card-copy {
  display: grid;
  gap: 6px;
}

.recent-published-card-copy strong {
  font: 700 1rem "Space Grotesk", sans-serif;
  color: #f5f8ff;
}

.recent-published-card-copy p {
  margin: 0;
  color: rgba(213, 223, 244, 0.76);
  line-height: 1.5;
}

.recent-published-card-metrics span {
  padding: 8px 12px;
  border-radius: 999px;
  color: rgba(234, 241, 255, 0.9);
  background: rgba(255, 255, 255, 0.05);
  box-shadow: inset 0 0 0 1px rgba(176, 203, 255, 0.08);
}

.recent-published-card-actions {
  justify-content: flex-end;
}

#deleteAgentRunError {
  min-height: 20px;
  color: #ffb8c8;
}

#cancelAgentRunError {
  min-height: 20px;
  color: #ffb8c8;
}

#openAiSetupModalError {
  min-height: 20px;
  color: #ffb8c8;
}

.marketing-preview-modal-card {
  width: min(1680px, calc(100vw - 24px));
  height: calc(100vh - 24px);
  max-height: calc(100vh - 24px);
  overflow: hidden;
  display: grid;
  grid-template-rows: max-content max-content minmax(0, 1fr);
  gap: 10px;
  background:
    radial-gradient(circle at top right, rgba(177, 104, 255, 0.14), transparent 24%),
    radial-gradient(circle at bottom left, rgba(79, 214, 255, 0.12), transparent 28%),
    linear-gradient(180deg, rgba(20, 26, 57, 0.98), rgba(8, 12, 28, 0.99));
}

.marketing-preview-modal-grid {
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  gap: 12px;
  min-height: 0;
  height: 100%;
}

.marketing-preview-sidebar {
  min-height: 0;
  overflow: auto;
  display: grid;
  align-content: start;
  gap: 12px;
  padding-right: 4px;
}

.marketing-preview-sidebar-readiness {
  display: grid;
  gap: 12px;
  padding: 16px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.04);
  box-shadow: inset 0 0 0 1px rgba(176, 203, 255, 0.08);
}

.marketing-preview-modal-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: nowrap;
  overflow-x: auto;
  overflow-y: hidden;
  padding-bottom: 2px;
}

.marketing-preview-modal-statuses,
.marketing-preview-modal-action-buttons {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: nowrap;
  flex: 0 0 auto;
}

.marketing-preview-sidebar-readiness.is-ready {
  background:
    radial-gradient(circle at top right, rgba(79, 214, 163, 0.12), transparent 38%),
    rgba(255, 255, 255, 0.04);
}

.marketing-preview-sidebar-readiness.is-blocked {
  background:
    radial-gradient(circle at top right, rgba(255, 120, 120, 0.14), transparent 38%),
    rgba(255, 255, 255, 0.04);
}

.marketing-preview-readiness-head {
  display: grid;
  gap: 8px;
}

.marketing-preview-readiness-head strong {
  color: #ffffff;
}

.marketing-preview-sidebar-actions .danger-button,
.marketing-preview-sidebar-actions .primary-button,
.marketing-preview-sidebar-actions .secondary-button {
  width: 100%;
}

.marketing-preview-sidebar-actions .primary-button.ghost {
  background:
    linear-gradient(180deg, rgba(72, 90, 164, 0.88), rgba(42, 55, 113, 0.92));
}

.marketing-preview-frame-shell {
  position: relative;
  min-height: 0;
  height: 100%;
  max-height: 100%;
  border-radius: 24px;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(14, 18, 38, 0.98), rgba(6, 8, 20, 0.99));
  box-shadow: inset 0 0 0 1px rgba(176, 203, 255, 0.08);
}

.marketing-preview-modal-action-buttons .primary-button,
.marketing-preview-modal-action-buttons .secondary-button,
.marketing-preview-modal-action-buttons .danger-button {
  min-height: 42px;
  white-space: nowrap;
}

.marketing-preview-frame {
  width: 100%;
  height: 100%;
  min-height: 0;
  border: 0;
  background: #0f152f;
}

.marketing-preview-sidebar::-webkit-scrollbar {
  width: 16px;
}

.marketing-preview-sidebar::-webkit-scrollbar-track {
  background: rgba(15, 21, 42, 0.88);
  border-radius: 999px;
}

.marketing-preview-sidebar::-webkit-scrollbar-thumb {
  border-radius: 999px;
  border: 3px solid rgba(15, 21, 42, 0.88);
  background: linear-gradient(180deg, rgba(119, 210, 255, 0.95), rgba(156, 123, 255, 0.95));
}

.marketing-preview-frame-empty {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  gap: 10px;
  padding: 24px;
  text-align: center;
  color: rgba(214, 224, 246, 0.82);
}

.marketing-preview-frame-empty strong {
  color: #ffffff;
  font: 700 1.1rem "Space Grotesk", sans-serif;
}

.agent-cadence-inline-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.agent-cadence-inline-meta .helper-text,
.agent-cadence-actions .helper-text {
  margin: 0;
  color: rgba(210, 219, 243, 0.76);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.agent-project-browser-copy,
.agent-project-browser-copy p,
.project-queue-head > div,
.output-review-card summary > div,
.marketing-run-card-copy,
.marketing-review-card-copy,
.marketing-review-card-title,
.mapping-meta,
.detail-kpi,
.detail-kpi strong,
.summary-row strong,
.module-rule-head,
.module-rule-note,
.module-signal-note {
  min-width: 0;
}

.mapping-meta,
.summary-row strong,
.detail-kpi strong,
.marketing-review-card-title strong,
.marketing-review-fact strong,
.module-rule-note,
.module-signal-note,
.project-queue-head strong {
  overflow-wrap: anywhere;
}

.mapping-meta {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.output-review-grid:empty {
  display: none;
}

.output-review-actions-inline {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.output-review-actions-inline button {
  min-height: 44px;
  font-weight: 600;
}

.agent-queue-empty {
  display: grid;
  gap: 10px;
  padding: 16px 18px;
}

.agent-queue-empty strong {
  color: #ffffff;
}

.agent-queue-empty span {
  color: rgba(210, 219, 243, 0.8);
  line-height: 1.45;
}

.agent-queue-empty-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.agent-workspace-shell[data-module-type="revenue_intelligence"] {
  grid-template-columns: 228px minmax(0, 1fr);
}

.agent-workspace-shell[data-module-type="revenue_intelligence"] .agent-output-rail {
  display: none;
}

.agent-workspace-shell[data-module-type="revenue_intelligence"] .agent-project-stage-head {
  grid-template-columns: minmax(0, 1.2fr) minmax(360px, 0.8fr);
  gap: 18px;
}

.agent-workspace-shell[data-module-type="revenue_intelligence"] .agent-stage-badges {
  justify-content: flex-start;
  align-content: start;
}

.agent-workspace-shell[data-module-type="revenue_intelligence"] .agent-project-stage {
  grid-template-rows: minmax(0, 1fr);
  gap: 0;
}

.agent-workspace-shell[data-module-type="revenue_intelligence"] #agentProjectStage {
  display: none;
}

.agent-workspace-shell[data-module-type="revenue_intelligence"] .agent-project-stage-head,
.agent-workspace-shell[data-module-type="revenue_intelligence"] #agentModuleOverviewCard {
  display: none;
}

.agent-workspace-shell[data-module-type="revenue_intelligence"].revenue-layout-compact {
  grid-template-columns: minmax(0, 1fr);
}

.agent-workspace-shell[data-module-type="revenue_intelligence"].revenue-layout-compact .agent-side-rail,
.agent-workspace-shell[data-module-type="revenue_intelligence"].revenue-layout-compact .agent-output-rail {
  display: none;
}

.agent-workspace-shell[data-module-type="revenue_intelligence"].revenue-layout-pipeline {
  grid-template-columns: 228px minmax(0, 1fr);
}

.agent-workspace-shell[data-module-type="revenue_intelligence"].revenue-layout-pipeline .agent-output-rail {
  display: none;
}

@media (max-width: 1320px) {
  #agentScreen.marketing-minimal-mode .workspace-header {
    grid-template-columns: 1fr;
  }

  #agentScreen.marketing-minimal-mode .agent-workspace-shell[data-layout="marketing-minimal"] {
    grid-template-columns: 1fr;
  }

  #agentScreen.marketing-minimal-mode .agent-center-stage,
  #agentScreen.marketing-minimal-mode .agent-output-rail,
  #agentScreen.marketing-minimal-mode .agent-side-rail {
    max-height: none;
    overflow: visible;
    padding-right: 0;
  }

  .marketing-minimal-hero {
    grid-template-columns: 1fr;
  }

  .marketing-minimal-hero-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .marketing-minimal-hero-actions {
    justify-items: start;
  }

  .marketing-frequency-stats,
  .marketing-auth-provider-metrics {
    grid-template-columns: 1fr;
  }

  .marketing-frequency-presets {
    grid-template-columns: 1fr;
  }

  .agent-command-head {
    grid-template-columns: 1fr;
  }

  .agent-workflow-step-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .agent-operations-shell {
    grid-template-columns: 1fr;
  }

  .marketing-review-row,
  .marketing-preview-modal-grid {
    grid-template-columns: 1fr;
  }

  .marketing-active-review-bar {
    grid-template-columns: 1fr;
  }

  .marketing-active-review-actions {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .marketing-review-row-inline,
  .marketing-preview-sidebar-facts {
    grid-template-columns: 1fr;
  }

  .marketing-review-actions.compact {
    justify-content: stretch;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .agent-workspace-shell[data-module-type="revenue_intelligence"] .agent-project-stage-head {
    grid-template-columns: 1fr;
  }

  .agent-workspace-shell[data-module-type="revenue_intelligence"] .agent-stage-badges {
    justify-content: flex-start;
  }
}

/* Final automation modernization: shared shell, right-side quick rail, tighter webhook and connector surfaces */
.workspace-sidebar-toggle-row {
  display: flex;
  justify-content: flex-end;
  padding-right: 6px;
  margin-top: -4px;
}

.workspace-sidebar-toggle {
  position: static;
  transform: none;
}

body.workspace-sidebar-collapsed .workspace-sidebar-toggle-row {
  justify-content: center;
  padding-right: 0;
}

#automationScreen .workspace-header {
  grid-template-columns: max-content minmax(320px, 1fr) max-content;
}

#automationScreen .workspace-header-actions {
  gap: 8px;
}

#automationScreen .workspace-utility-strip {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

#automationScreen .automation-view-pill,
#automationScreen .automation-status-pill {
  width: 100%;
  text-align: left;
}

#automationScreen .automation-view-pill {
  cursor: pointer;
}

#automationScreen .automation-view-pill.active {
  border-color: rgba(149, 208, 255, 0.22);
  background:
    radial-gradient(circle at top left, rgba(83, 167, 255, 0.18), transparent 36%),
    radial-gradient(circle at top right, rgba(164, 103, 255, 0.18), transparent 38%),
    linear-gradient(180deg, rgba(48, 61, 108, 0.98), rgba(24, 31, 61, 0.98));
}

#automationScreen .automation-status-pill {
  cursor: default;
}

#automationScreen .workspace-panel {
  padding: 12px;
}

#automationScreen .main-grid {
  grid-template-columns: minmax(0, 1fr) 286px;
  gap: 12px;
}

#automationScreen .content {
  order: 1;
  display: grid;
  gap: 14px;
}

#automationScreen .sidebar {
  order: 2;
  gap: 12px;
  position: static;
}

#automationScreen .sidebar-card {
  gap: 12px;
  padding: 14px;
  border-radius: 20px;
  background:
    radial-gradient(circle at top right, rgba(118, 104, 255, 0.12), transparent 34%),
    linear-gradient(180deg, rgba(23, 29, 56, 0.94), rgba(11, 16, 34, 0.98));
}

#automationScreen .sidebar-card .panel-head h4 {
  margin: 0;
}

#automationScreen .nav-button {
  min-height: 46px;
  border-radius: 14px;
  padding: 12px 14px;
  background:
    linear-gradient(180deg, rgba(37, 43, 76, 0.88), rgba(18, 23, 45, 0.94));
  color: rgba(242, 247, 255, 0.96);
}

#automationScreen .nav-button.active {
  background:
    radial-gradient(circle at left center, rgba(121, 196, 255, 0.18), transparent 30%),
    linear-gradient(135deg, rgba(89, 108, 190, 0.98), rgba(57, 69, 124, 0.98));
}

#automationScreen .automation-side-notes .stack-item {
  padding: 12px 14px;
}

#automationScreen .automation-side-notes strong,
#automationScreen .automation-quick-action strong,
#automationScreen .automation-health-item strong,
#automationScreen .automation-connector-card strong {
  color: #ffffff;
}

#automationScreen .automation-side-notes div,
#automationScreen .automation-quick-action span,
#automationScreen .automation-health-item span,
#automationScreen .automation-connector-card p,
#automationScreen .automation-connector-meta {
  color: rgba(208, 217, 241, 0.78);
}

#automationScreen .feed-list {
  display: grid;
  gap: 8px;
}

#automationScreen .feed-list li {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(176, 198, 255, 0.08);
}

#automationScreen .view-panel {
  display: none;
}

#automationScreen .view-panel.active {
  display: grid;
  gap: 14px;
}

.automation-section-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 14px;
  align-items: start;
}

.automation-webhook-grid {
  display: grid;
  grid-template-columns: minmax(340px, 0.86fr) minmax(0, 1.14fr);
  gap: 14px;
  align-items: start;
}

.automation-webhook-detail-column,
.automation-connector-card-grid,
.automation-health-grid,
.automation-quick-actions {
  display: grid;
  gap: 10px;
}

.automation-quick-action {
  width: 100%;
  display: grid;
  gap: 4px;
  text-align: left;
  padding: 12px 14px;
  border-radius: 16px;
  color: inherit;
  border: 1px solid rgba(176, 198, 255, 0.12);
  background:
    linear-gradient(180deg, rgba(34, 41, 74, 0.92), rgba(18, 24, 47, 0.95)),
    linear-gradient(145deg, rgba(255, 255, 255, 0.04), transparent);
  cursor: pointer;
}

.automation-health-grid {
  grid-template-columns: 1fr;
}

.automation-health-item {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(176, 198, 255, 0.08);
}

.automation-connector-grid,
.automation-connector-ops-grid,
.automation-destination-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.82fr) minmax(0, 1.18fr);
  gap: 14px;
}

.automation-builder-panel .builder-grid {
  grid-template-columns: minmax(0, 1.05fr) minmax(280px, 0.95fr);
}

.automation-connector-card-grid {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.automation-connector-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(176, 198, 255, 0.12);
  background:
    radial-gradient(circle at top right, rgba(140, 110, 255, 0.14), transparent 32%),
    linear-gradient(180deg, rgba(33, 41, 74, 0.94), rgba(18, 24, 47, 0.96));
}

.automation-connector-card-system {
  background:
    radial-gradient(circle at top right, rgba(101, 197, 255, 0.14), transparent 32%),
    linear-gradient(180deg, rgba(33, 41, 74, 0.94), rgba(18, 24, 47, 0.96));
}

.automation-connector-card-head {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.automation-connector-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, rgba(93, 176, 255, 0.94), rgba(158, 104, 255, 0.94));
  box-shadow: 0 12px 24px rgba(24, 33, 65, 0.18);
}

.automation-connector-icon svg {
  width: 20px;
  height: 20px;
}

.automation-connector-chip-row,
.automation-connector-meta {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.automation-connector-meta {
  font-size: 0.78rem;
}

.automation-recommendation-list {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.automation-recommendation-item {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(176, 198, 255, 0.08);
}

.automation-recommendation-item strong {
  color: #ffffff;
}

.automation-recommendation-item span {
  color: rgba(208, 217, 241, 0.78);
  font-size: 0.82rem;
  line-height: 1.4;
}

.signals-hero-shell,
.admin-command-shell,
.automation-setup-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(260px, 0.8fr);
  gap: 14px;
  padding: 18px 20px;
  border-radius: 24px;
  border: 1px solid rgba(170, 194, 255, 0.12);
  background:
    radial-gradient(circle at top left, rgba(88, 177, 255, 0.14), transparent 34%),
    radial-gradient(circle at bottom right, rgba(123, 98, 255, 0.16), transparent 36%),
    linear-gradient(180deg, rgba(25, 31, 59, 0.96), rgba(12, 17, 35, 0.98));
}

.signals-hero-copy,
.admin-command-copy {
  display: grid;
  gap: 8px;
}

.signals-hero-copy h3,
.admin-command-copy h3,
.automation-setup-card h4 {
  margin: 0;
  color: #ffffff;
}

.signals-hero-badges {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  justify-content: flex-end;
  flex-wrap: wrap;
}

.signals-glance-strip,
.admin-glance-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.glance-card {
  display: grid;
  gap: 8px;
  min-height: 136px;
  border-radius: 20px;
  border: 1px solid rgba(178, 198, 255, 0.12);
  background:
    radial-gradient(circle at top right, rgba(109, 182, 255, 0.12), transparent 32%),
    linear-gradient(180deg, rgba(27, 34, 64, 0.96), rgba(14, 19, 39, 0.98));
}

.glance-card h3,
.glance-card p:last-child,
.signals-insight-card h4,
.signals-action-item strong,
.admin-priority-item strong,
.admin-pulse-item strong,
.automation-setup-item strong,
.automation-empty-callout strong {
  color: #ffffff;
}

.glance-card p:last-child,
.signals-insight-body,
.signals-action-item p,
.admin-priority-item p,
.admin-pulse-item p,
.automation-setup-item p,
.automation-empty-callout p {
  margin: 0;
  color: rgba(208, 217, 241, 0.8);
  line-height: 1.5;
}

.glance-card-warning {
  box-shadow: inset 0 0 0 1px rgba(255, 193, 94, 0.14);
}

.glance-card-critical {
  box-shadow: inset 0 0 0 1px rgba(255, 113, 113, 0.18);
}

.glance-card-positive {
  box-shadow: inset 0 0 0 1px rgba(111, 234, 173, 0.14);
}

.signals-insight-grid,
.admin-overview-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
  gap: 14px;
}

.signals-insight-card,
.admin-section-shell,
.admin-priority-board,
.admin-pulse-card,
.automation-setup-card,
.automation-empty-callout {
  display: grid;
  gap: 12px;
  padding: 16px 18px;
  border-radius: 22px;
  border: 1px solid rgba(178, 198, 255, 0.12);
  background:
    linear-gradient(180deg, rgba(28, 35, 67, 0.96), rgba(15, 20, 40, 0.98));
}

.signals-insight-card-secondary,
.automation-setup-card {
  align-content: start;
}

.signals-mini-grid,
.admin-pulse-grid,
.automation-setup-list,
.automation-setup-glance,
.signals-action-list,
.admin-priority-list {
  display: grid;
  gap: 10px;
}

.signals-mini-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.signals-action-item,
.admin-priority-item,
.admin-pulse-item,
.automation-setup-item,
.automation-setup-glance-item {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(176, 198, 255, 0.08);
}

.automation-setup-glance {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.automation-setup-glance-item span {
  color: rgba(188, 202, 236, 0.76);
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.automation-setup-glance-item strong {
  color: #ffffff;
  font-size: 1.36rem;
  letter-spacing: -0.04em;
}

.admin-pulse-item span {
  color: rgba(188, 202, 236, 0.78);
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.signals-detail-grid {
  align-items: start;
}

.signals-detail-card {
  min-height: 100%;
}

.automation-setup-card-primary {
  background:
    radial-gradient(circle at top left, rgba(95, 186, 255, 0.16), transparent 32%),
    linear-gradient(180deg, rgba(31, 38, 73, 0.96), rgba(16, 22, 43, 0.98));
}

.automation-empty-callout {
  margin-top: 4px;
}

#automationScreen .webhook-control-panel {
  margin-top: 0;
}

#automationScreen .webhook-studio {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-bottom: 0;
}

#automationScreen .compact-webhook-form {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

#automationScreen .compact-webhook-actions {
  align-items: center;
}

#automationScreen .topbar-actions {
  gap: 10px;
}

@media (max-width: 1400px) {
  .signals-insight-grid,
  .admin-overview-grid,
  .signals-hero-shell,
  .admin-command-shell,
  .automation-setup-shell,
  .automation-webhook-grid,
  .automation-connector-grid,
  .automation-connector-ops-grid,
  .automation-destination-grid,
  #automationScreen .compact-webhook-form,
  .automation-builder-panel .builder-grid {
    grid-template-columns: 1fr;
  }

  #automationScreen .webhook-studio {
    grid-template-columns: 1fr;
  }

  .signals-mini-grid {
    grid-template-columns: 1fr;
  }

  .automation-setup-glance {
    grid-template-columns: 1fr;
  }
}

/* Marketing workspace simplification overrides */
#agentScreen.marketing-minimal-mode .agent-workspace-shell[data-layout="marketing-minimal"] {
  grid-template-columns: minmax(0, 1fr) 240px;
  gap: 16px;
}

#agentScreen.marketing-minimal-mode #marketingMinimalHero,
#agentScreen.marketing-minimal-mode #agentProjectStage,
#agentScreen.marketing-minimal-mode #agentCadencePanel,
#agentScreen.marketing-minimal-mode #marketingFrequencyCard {
  display: none !important;
}

#agentScreen.marketing-minimal-mode .agent-operations-shell {
  gap: 14px;
}

#agentScreen.marketing-minimal-mode .agent-review-panel,
#agentScreen.marketing-minimal-mode .agent-queue-panel,
#agentScreen.marketing-minimal-mode .marketing-published-panel,
#agentScreen.marketing-minimal-mode .agent-workflow-panel {
  border-radius: 22px;
}

#agentScreen.marketing-minimal-mode .agent-workflow-panel {
  padding: 18px 16px;
}

#agentScreen.marketing-minimal-mode #agentSetupPanelSummary,
#agentScreen.marketing-minimal-mode .marketing-panel-summary {
  display: none;
}

#agentScreen.marketing-minimal-mode #agentOutputsList,
#agentScreen.marketing-minimal-mode #agentRunsList,
#agentScreen.marketing-minimal-mode #marketingPublishedList {
  overflow: visible !important;
  max-height: none !important;
  padding-right: 0 !important;
}

.marketing-inline-frequency {
  display: grid;
  gap: 8px;
  margin-bottom: 12px;
}

.marketing-inline-frequency-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 10px;
}

.marketing-inline-frequency-label {
  color: rgba(188, 202, 236, 0.76);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.marketing-inline-frequency-head strong {
  color: #ffffff;
  font: 800 0.9rem "Space Grotesk", sans-serif;
  text-align: right;
}

.marketing-inline-frequency-buttons {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.marketing-inline-frequency-button {
  min-height: 38px;
  border-radius: 14px;
  border: 1px solid rgba(170, 193, 255, 0.12);
  background: rgba(24, 31, 61, 0.88);
  color: #e8efff;
  font: 700 0.84rem "Space Grotesk", sans-serif;
  cursor: pointer;
  transition: transform 140ms ease, border-color 140ms ease, background 140ms ease;
}

.marketing-inline-frequency-button:hover {
  transform: translateY(-1px);
  border-color: rgba(132, 202, 255, 0.32);
}

.marketing-inline-frequency-button.active {
  background: linear-gradient(135deg, rgba(72, 132, 220, 0.66), rgba(102, 86, 196, 0.66));
  border-color: rgba(130, 188, 255, 0.44);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.marketing-schedule-summary {
  display: grid;
  gap: 6px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(154, 177, 232, 0.14);
  background: rgba(9, 18, 43, 0.34);
  color: rgba(216, 226, 249, 0.8);
  font-size: 0.78rem;
  line-height: 1.35;
}

.marketing-schedule-summary strong,
.marketing-schedule-summary .is-live {
  color: #8df1d6;
}

.marketing-schedule-summary .is-warning {
  color: #ffb3c5;
}

.marketing-schedule-summary .is-muted {
  color: rgba(189, 201, 230, 0.66);
}

.marketing-auth-quick-grid {
  grid-template-columns: 1fr;
  gap: 8px;
}

.marketing-auth-quick-button {
  gap: 3px;
  padding: 12px 14px;
  min-height: 56px;
  border-radius: 16px;
}

#agentScreen.marketing-minimal-mode .marketing-panel-head-actions .primary-button,
#agentScreen.marketing-minimal-mode .marketing-minimal-hero-actions .primary-button,
#agentScreen.marketing-minimal-mode .marketing-publish-success-actions .primary-button,
#agentScreen.marketing-minimal-mode #agentRunWorkflowBtn,
#agentScreen.marketing-minimal-mode #agentQueueRunWorkflowBtn {
  background: linear-gradient(135deg, rgba(86, 155, 255, 0.48), rgba(124, 92, 255, 0.48));
  box-shadow: 0 10px 20px rgba(74, 95, 255, 0.10), inset 0 1px 0 rgba(255,255,255,0.08);
}

/* Marketing module top / middle / bottom layout */
#agentScreen.marketing-minimal-mode .agent-center-stage {
  gap: 10px;
}

#agentScreen.marketing-minimal-mode .agent-operations-shell {
  grid-template-columns: 1fr;
  gap: 10px;
}

#agentScreen.marketing-minimal-mode .agent-queue-panel {
  order: 1;
}

#agentScreen.marketing-minimal-mode .agent-review-panel {
  order: 2;
}

#agentScreen.marketing-minimal-mode .marketing-published-panel {
  order: 3;
}

#agentScreen.marketing-minimal-mode .agent-queue-panel,
#agentScreen.marketing-minimal-mode .agent-review-panel,
#agentScreen.marketing-minimal-mode .marketing-published-panel {
  padding: 14px 16px;
  border: 1px solid rgba(126, 196, 193, 0.14);
  background:
    radial-gradient(circle at top right, rgba(90, 190, 165, 0.08), transparent 28%),
    linear-gradient(180deg, rgba(23, 31, 61, 0.97), rgba(12, 18, 37, 0.99));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 20px 44px rgba(5, 10, 24, 0.18);
}

#agentScreen.marketing-minimal-mode .marketing-panel-head {
  margin-bottom: 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(166, 189, 255, 0.09);
}

#agentScreen.marketing-minimal-mode .marketing-panel-head h4 {
  margin: 2px 0 0;
  color: #f8fbff;
  font: 700 0.98rem "Space Grotesk", sans-serif;
}

#agentScreen.marketing-minimal-mode .marketing-panel-head .eyebrow {
  color: rgba(117, 222, 184, 0.9);
}

#agentScreen.marketing-minimal-mode .marketing-panel-head-actions {
  gap: 8px;
}

#agentScreen.marketing-minimal-mode .marketing-panel-head-actions .secondary-button,
#agentScreen.marketing-minimal-mode .marketing-panel-head-actions .primary-button {
  min-height: 34px;
  padding: 0 12px;
  border-radius: 10px;
  font-size: 0.82rem;
}

#agentScreen.marketing-minimal-mode .marketing-run-card {
  border-radius: 16px;
  border-color: rgba(104, 217, 179, 0.18);
  background:
    radial-gradient(circle at top right, rgba(104, 217, 179, 0.09), transparent 24%),
    linear-gradient(180deg, rgba(34, 44, 81, 0.96), rgba(17, 24, 48, 0.99));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 18px 36px rgba(7, 12, 26, 0.16);
}

#agentScreen.marketing-minimal-mode .marketing-run-summary {
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 10px;
  align-items: start;
  padding: 12px 14px;
}

#agentScreen.marketing-minimal-mode .marketing-run-summary-actions {
  grid-column: 1 / -1;
  justify-content: flex-start;
}

#agentScreen.marketing-minimal-mode .compact-run-action {
  min-height: 32px;
  padding: 0 10px;
  border-radius: 10px;
}

#agentScreen.marketing-minimal-mode .marketing-run-details {
  padding: 0 14px 12px;
}

#agentScreen.marketing-minimal-mode .marketing-run-stage-strip {
  gap: 6px;
}

#agentScreen.marketing-minimal-mode .marketing-run-stage-pill {
  min-height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  font-size: 0.68rem;
}

#agentScreen.marketing-minimal-mode .marketing-review-row {
  grid-template-columns: 120px minmax(0, 1fr) max-content;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  border-color: rgba(242, 187, 90, 0.16);
  background:
    radial-gradient(circle at top right, rgba(242, 187, 90, 0.07), transparent 28%),
    linear-gradient(180deg, rgba(28, 34, 64, 0.98), rgba(14, 18, 36, 0.99));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 16px 32px rgba(7, 12, 26, 0.14);
}

#agentScreen.marketing-minimal-mode .marketing-review-row-accent {
  min-height: 72px;
  padding: 12px;
  border-radius: 16px;
  background:
    radial-gradient(circle at top right, rgba(114, 210, 255, 0.18), transparent 34%),
    linear-gradient(160deg, rgba(40, 59, 110, 0.98), rgba(20, 27, 54, 0.98));
}

#agentScreen.marketing-minimal-mode .marketing-review-row .marketing-review-card-title strong {
  font-size: 0.94rem;
}

#agentScreen.marketing-minimal-mode .marketing-review-actions.compact {
  grid-template-columns: repeat(3, max-content);
  align-items: center;
  gap: 8px;
}

#agentScreen.marketing-minimal-mode .marketing-review-actions.compact .secondary-button,
#agentScreen.marketing-minimal-mode .marketing-review-actions.compact .primary-button {
  min-height: 32px;
  padding: 0 12px;
  border-radius: 10px;
  font-size: 0.8rem;
}

#agentScreen.marketing-minimal-mode .marketing-card-menu-toggle {
  border-radius: 10px;
}

.marketing-published-panel {
  display: grid;
  gap: 10px;
}

.marketing-published-list {
  display: grid;
  gap: 12px;
}

.marketing-published-card,
.marketing-published-empty {
  border-radius: 18px;
  border: 1px solid rgba(126, 196, 193, 0.12);
  background:
    radial-gradient(circle at top right, rgba(104, 217, 179, 0.07), transparent 24%),
    linear-gradient(180deg, rgba(27, 36, 66, 0.96), rgba(13, 19, 38, 0.99));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 14px 30px rgba(6, 11, 24, 0.12);
}

.marketing-published-card {
  padding: 12px 14px;
}

.marketing-published-card-main {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr) max-content;
  gap: 12px;
  align-items: center;
}

.marketing-published-card-badge {
  display: grid;
  gap: 4px;
  min-height: 64px;
  align-content: center;
  padding: 12px;
  border-radius: 16px;
  background:
    radial-gradient(circle at top right, rgba(104, 217, 179, 0.16), transparent 34%),
    linear-gradient(160deg, rgba(27, 75, 72, 0.98), rgba(14, 34, 41, 0.98));
  box-shadow: inset 0 0 0 1px rgba(126, 226, 187, 0.12);
}

.marketing-published-card-badge span {
  color: rgba(201, 237, 223, 0.74);
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.marketing-published-card-badge strong {
  color: #ffffff;
  font: 700 0.98rem "Space Grotesk", sans-serif;
}

.marketing-published-card-copy,
.marketing-published-card-head {
  display: grid;
  gap: 8px;
}

.marketing-published-card-head {
  grid-template-columns: minmax(0, 1fr) max-content;
  align-items: start;
}

.marketing-published-card-copy strong {
  color: #f7fbff;
  font: 700 0.92rem "Space Grotesk", sans-serif;
}

.marketing-published-card-copy p,
.marketing-published-card-meta {
  margin: 0;
  color: rgba(205, 215, 239, 0.78);
  font-size: 0.8rem;
  line-height: 1.35;
}

.marketing-published-card-meta,
.marketing-published-card-statuses,
.marketing-published-card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.marketing-published-card-actions {
  justify-content: flex-end;
}

.marketing-published-card-actions .secondary-button {
  min-height: 32px;
  padding: 0 12px;
  border-radius: 10px;
  font-size: 0.8rem;
}

.marketing-published-empty {
  display: grid;
  gap: 6px;
  padding: 14px;
  color: rgba(205, 215, 239, 0.78);
}

.marketing-section-footnote {
  margin-top: 6px;
  color: rgba(189, 201, 230, 0.68);
  font-size: 0.74rem;
  line-height: 1.3;
}

#agentScreen.marketing-minimal-mode .marketing-queue-empty,
#agentScreen.marketing-minimal-mode .marketing-review-empty {
  gap: 8px;
  padding: 14px 16px;
  border-radius: 16px;
}

#agentScreen.marketing-minimal-mode .marketing-queue-empty strong,
#agentScreen.marketing-minimal-mode .marketing-review-empty strong {
  font-size: 0.95rem;
}

#agentScreen.marketing-minimal-mode .marketing-queue-empty-summary {
  font-size: 0.8rem;
  line-height: 1.35;
}

#agentScreen.marketing-minimal-mode .agent-queue-empty-actions {
  gap: 8px;
}

#agentScreen.marketing-minimal-mode .agent-queue-empty-actions .primary-button,
#agentScreen.marketing-minimal-mode .agent-queue-empty-actions .secondary-button {
  min-height: 34px;
  padding: 0 12px;
  font-size: 0.82rem;
}

@media (max-width: 1320px) {
  #agentScreen.marketing-minimal-mode .marketing-review-row,
  .marketing-published-card-main,
  #agentScreen.marketing-minimal-mode .marketing-run-summary {
    grid-template-columns: 1fr;
  }

  #agentScreen.marketing-minimal-mode .marketing-review-actions.compact,
  .marketing-published-card-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 1200px) {
  .workspace-main {
    order: 1;
  }

  .workspace-sidebar {
    order: 2;
  }

  #dashboardScreen.active,
  #agentScreen.active,
  #automationScreen.active,
  #reportsScreen.active,
  #platformAdminScreen.active {
    height: auto;
    min-height: calc(100dvh - 24px);
  }

  .workspace-shell,
  .workspace-shell-inner,
  .workspace-header,
  .workspace-header-actions,
  .workspace-home-grid,
  .workspace-detail-grid,
  .workspace-project-grid,
  .workspace-project-stats,
  .workspace-metric-grid,
  .agent-workspace-shell,
  .agent-workspace-shell.revenue-layout-compact,
  .agent-workspace-shell.revenue-layout-pipeline,
  .module-overview-shell,
  .revenue-pipeline-shell,
  .revenue-chart-grid {
    grid-template-columns: 1fr;
  }

  .workspace-sidebar {
    position: static;
    top: auto;
  }

  .workspace-brand-card,
  .workspace-sidebar-section {
    padding: 14px;
    border-radius: 20px;
  }

  .workspace-shell-topbar,
  .workspace-shell-status,
  .workspace-header {
    gap: 10px;
  }

  .workspace-utility-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #agentScreen .workspace-main,
  #dashboardScreen .workspace-main,
  #automationScreen .workspace-main,
  #reportsScreen .workspace-main,
  #platformAdminScreen .workspace-main {
    min-height: auto;
  }

  #automationScreen .content {
    order: 1;
  }

  #automationScreen .sidebar {
    order: 2;
  }

  .signals-hero-shell,
  .admin-command-shell,
  .automation-setup-shell {
    gap: 10px;
    padding: 14px 16px;
    border-radius: 20px;
  }

  .signals-glance-strip,
  .admin-glance-strip {
    gap: 10px;
  }

  .glance-card,
  .signals-insight-card,
  .admin-section-shell,
  .admin-priority-board,
  .admin-pulse-card,
  .automation-setup-card,
  .automation-empty-callout {
    min-height: 0;
    padding: 14px 16px;
    border-radius: 18px;
  }

  .revenue-tab-panel[data-revenue-tab-panel="pipeline"] {
    max-height: calc(100dvh - 234px);
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 4px;
  }

  .revenue-tab-panel[data-revenue-tab-panel="pipeline"] .revenue-pipeline-shell {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .revenue-tab-panel[data-revenue-tab-panel="pipeline"] .revenue-pipeline-shell > .module-panel:first-child {
    order: 2;
  }

  .revenue-tab-panel[data-revenue-tab-panel="pipeline"] .revenue-pipeline-shell > .module-panel:last-child {
    order: 1;
  }

  .revenue-tab-panel[data-revenue-tab-panel="pipeline"] .revenue-report-cards,
  .revenue-tab-panel[data-revenue-tab-panel="pipeline"] .revenue-chart-grid {
    gap: 10px;
  }

  .revenue-tab-panel[data-revenue-tab-panel="pipeline"] .revenue-chart-card,
  .revenue-tab-panel[data-revenue-tab-panel="pipeline"] .revenue-report-card,
  .revenue-tab-panel[data-revenue-tab-panel="reports"] .revenue-chart-card,
  .revenue-tab-panel[data-revenue-tab-panel="reports"] .revenue-glance-card {
    min-height: 0;
    padding: 14px;
    border-radius: 18px;
  }

  .revenue-tab-panel[data-revenue-tab-panel="reports"] {
    max-height: calc(100dvh - 234px);
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 4px;
    gap: 12px;
  }

  .revenue-tab-panel[data-revenue-tab-panel="reports"] .revenue-chart-grid {
    gap: 10px;
  }

  .revenue-tab-panel[data-revenue-tab-panel="reports"] .revenue-glance-strip {
    gap: 10px;
  }

  .revenue-board-column {
    max-height: min(62dvh, 720px);
    overflow-y: auto;
    padding: 10px;
  }

  .revenue-board-card {
    gap: 8px;
    padding: 12px;
    border-radius: 18px;
  }

  .revenue-pipeline-drawer {
    margin-top: 12px;
    padding: 16px;
    border-radius: 20px;
  }
}

@media (max-width: 900px) {
  html,
  body {
    height: auto;
    min-height: 100%;
    overflow-x: hidden;
  }

  body.viewport-locked {
    overflow-y: auto;
  }

  .app-shell {
    height: auto !important;
    min-height: 100dvh;
    overflow: visible !important;
    padding-bottom: calc(96px + env(safe-area-inset-bottom, 0px));
  }

  #dashboardScreen.active,
  #agentScreen.active,
  #automationScreen.active,
  #reportsScreen.active,
  #platformAdminScreen.active {
    height: auto;
    min-height: auto;
    overflow: visible !important;
  }

  .app-shell {
    width: 100%;
    padding: 12px 12px calc(96px + env(safe-area-inset-bottom, 0px));
  }

  .workspace-shell,
  .workspace-shell-inner {
    min-height: auto;
    gap: 14px;
  }

  .workspace-sidebar {
    order: 2;
  }

  .workspace-main,
  #agentScreen .workspace-main,
  #dashboardScreen .workspace-main,
  #automationScreen .workspace-main,
  #reportsScreen .workspace-main,
  #platformAdminScreen .workspace-main {
    min-height: auto !important;
    height: auto;
    overflow: visible !important;
    padding-right: 0;
  }

  .workspace-brand-card {
    grid-template-columns: 48px minmax(0, 1fr) 40px;
    min-height: auto;
  }

  .workspace-nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: stretch;
  }

  .workspace-nav-button {
    min-height: 54px;
  }

  .workspace-utility-strip,
  .revenue-pipeline-drawer-glance,
  .revenue-pipeline-stage-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .revenue-pipeline-drawer-body,
  .agent-grid,
  .app-grid,
  .builder-grid,
  .card-grid {
    grid-template-columns: 1fr !important;
  }

  .revenue-pipeline-board {
    grid-auto-columns: minmax(240px, 82vw);
  }

  .revenue-module-tabbar,
  .revenue-tab-panel,
  .content-list {
    scrollbar-gutter: auto;
  }

  .topbar {
    position: static;
    padding: 0;
    background: none;
    backdrop-filter: none;
  }
}

@media (max-width: 640px) {
  .app-shell,
  .screen.active,
  .workspace-shell,
  .workspace-shell-inner,
  .workspace-main,
  .workspace-panel,
  .workspace-command-center,
  .workspace-command-layout,
  .workspace-command-main,
  .workspace-command-side-shell,
  .workspace-home-grid,
  .workspace-project-grid,
  .workspace-project-card,
  .agent-workspace-shell,
  .module-overview-shell,
  .revenue-workspace-grid,
  .revenue-pipeline-shell,
  .revenue-tab-panel,
  .agent-studio-module-catalog,
  .agent-studio-module-card {
    min-width: 0;
    max-width: 100%;
  }

  .app-shell,
  .workspace-shell,
  .workspace-shell-inner,
  .workspace-main {
    overflow-x: hidden;
  }

  .workspace-brand-card,
  .workspace-sidebar-section,
  .workspace-panel,
  .workspace-project-card,
  .workspace-mini-panel,
  .workspace-list-item {
    border-radius: 20px;
    padding: 14px;
  }

  .workspace-nav,
  .workspace-utility-strip,
  .workspace-header-actions,
  .revenue-pipeline-drawer-glance,
  .revenue-pipeline-stage-actions {
    grid-template-columns: 1fr;
  }

  .workspace-header,
  .workspace-shell-topbar,
  .workspace-shell-status,
  .workspace-command-main .workspace-metric-grid,
  .agent-studio-module-catalog,
  .workspace-project-grid,
  .revenue-workspace-grid {
    grid-template-columns: 1fr !important;
  }

  .workspace-nav-button,
  .workspace-header .secondary-button,
  .workspace-header .primary-button,
  .workspace-user-pill {
    width: 100%;
    min-width: 0;
  }

  .workspace-brand-tagline {
    white-space: normal;
  }

  #dashboardScreen .workspace-project-card,
  .workspace-project-card,
  .agent-studio-module-card {
    min-height: 0;
  }

  #dashboardScreen .workspace-project-card {
    padding: 14px;
  }

  #agentScreen .agent-studio-module-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .revenue-module-tabbar {
    width: 100%;
    max-width: 100%;
    padding-inline: 8px;
  }

  .revenue-module-tab {
    min-width: 132px;
    padding-inline: 12px;
  }

  .revenue-pipeline-board {
    grid-auto-columns: minmax(250px, 88vw);
  }

  .revenue-pipeline-shell,
  .revenue-pipeline-board,
  .revenue-pipeline-drawer,
  .revenue-board-column {
    max-width: 100%;
  }

  .revenue-board-column {
    min-width: 0;
  }
}

/* Backend QA stability pass: keep app routes balanced and tappable across viewport sizes. */
.workspace-main {
  align-content: start;
  grid-auto-rows: max-content;
}

#dashboardScreen .workspace-panel {
  height: auto;
  min-height: 0;
}

#dashboardScreen .workspace-panel:has(> .workspace-project-grid) {
  overflow: visible;
}

#dashboardScreen .workspace-panel > .workspace-project-grid {
  min-height: 0;
}

.view-panel,
.view-panel.active,
.signals-hero-shell,
#reportsFilterForm,
.workspace-aux-panel > * {
  min-width: 0;
  max-width: 100%;
}

#reportsScreen .view-panel.active {
  display: grid;
  gap: 16px;
  grid-template-columns: minmax(0, 1fr) !important;
  width: 100%;
  overflow: hidden;
}

#reportsScreen .view-panel.active > *,
#reportsScreen .signals-hero-shell,
#reportsScreen #reportsFilterForm,
#reportsScreen .panel-head,
#reportsScreen .input-card,
#reportsScreen .input-card input {
  min-width: 0;
  max-width: 100%;
  width: 100%;
}

@media (max-width: 640px) {
  .app-shell,
  .screen.active,
  .workspace-shell,
  .workspace-shell-inner,
  .workspace-main,
  .workspace-header,
  .workspace-route-chip,
  .workspace-utility-strip,
  .workspace-header-actions,
  .workspace-panel,
  .view-panel,
  .view-panel.active,
  .signals-hero-shell,
  #reportsFilterForm {
    width: 100%;
    min-width: 0;
    max-width: 100%;
  }

  .workspace-header,
  .workspace-header-actions,
  .signals-hero-shell,
  .signals-hero-badges,
  .panel-head,
  #reportsFilterForm,
  #agentScreen .agent-studio-module-head,
  #agentScreen .agent-studio-module-foot,
  #agentScreen .agent-studio-module-actions {
    grid-template-columns: 1fr !important;
    justify-content: stretch;
  }

  #agentScreen .agent-studio-module-head,
  #agentScreen .agent-studio-module-foot,
  #agentScreen .agent-studio-module-actions {
    display: grid;
  }

  #agentScreen .agent-studio-module-title {
    min-width: 0;
  }

  #agentScreen .agent-studio-module-actions .pill,
  .signals-hero-badges .pill {
    width: 100%;
    justify-content: center;
    white-space: normal;
    text-align: center;
  }

  .workspace-route-chip {
    overflow-wrap: anywhere;
  }

  #reportsScreen .workspace-aux-panel {
    overflow: hidden;
  }
}

@media (max-width: 1320px) {
  .onboarding-flow-layout,
  .onboarding-step-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .onboarding-builder-card {
    grid-column: 1 / -1;
  }
}

@media (max-width: 720px) {
  .onboarding-flow-head,
  .onboarding-flow-actions {
    align-items: stretch;
    justify-content: stretch;
  }

  .onboarding-flow-actions .primary-button,
  .onboarding-flow-actions .secondary-button,
  .onboarding-flow-actions .pill {
    width: 100%;
    justify-content: center;
  }

  .onboarding-flow-layout,
  .onboarding-step-grid,
  .onboarding-builder-tabs,
  .onboarding-builder-detail-grid {
    grid-template-columns: 1fr;
  }

.builder-onboarding-callout ol {
    columns: 1;
  }
}

/* Mobile app shell hardening */
.mobile-app-nav {
  display: none;
}

@media (max-width: 720px) {
  html {
    scroll-padding-top: 84px;
  }

  body {
    overflow-x: hidden;
  }

  .app-shell {
    width: 100%;
    max-width: 100%;
    padding: 10px 10px 104px;
  }

  body[data-active-screen="loginScreen"] .app-shell {
    padding-bottom: 18px;
  }

  .screen.active,
  .workspace-shell,
  .workspace-main,
  .workspace-panel,
  .workspace-home-grid,
  .workspace-detail-grid,
  .workspace-project-grid,
  .workspace-project-stats,
  .workspace-metric-grid,
  .card-grid,
  .main-grid,
  .content,
  .view-panel,
  .info-card,
  .agent-grid,
  .webhook-studio,
  .summary-list,
  .content-list {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow-x: clip;
  }

  #loginScreen.screen.active {
    display: block;
  }

  .login-layout.auth-layout-dark {
    display: block;
    min-height: 0;
    padding: 0;
  }

  .auth-stack {
    width: 100%;
    max-width: 100%;
  }

  .auth-entry-card,
  .login-card.auth-card-shell {
    margin: 0;
    padding: 16px;
    border-radius: 20px;
  }

  .auth-entry-heading {
    font-size: 1.35rem;
    line-height: 1.08;
  }

  .auth-hero-card {
    display: none;
  }

  .auth-form-grid {
    gap: 12px;
  }

  .auth-form-grid .field,
  .auth-form-grid input,
  .auth-form-grid .primary-button,
  .full-button {
    width: 100%;
  }

  .auth-form-grid input,
  .auth-form-grid .primary-button,
  .secondary-button,
  .primary-button,
  .nav-button,
  .workspace-nav-button {
    min-height: 48px;
  }

  .workspace-shell {
    display: block;
  }

  .workspace-sidebar {
    display: none;
  }

  .workspace-main {
    display: grid;
    gap: 12px;
  }

  .workspace-header,
  .workspace-panel-head,
  .topbar {
    position: sticky;
    top: 0;
    z-index: 20;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
    padding: 12px;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(11, 19, 41, 0.97), rgba(6, 12, 30, 0.96));
    border: 1px solid rgba(159, 181, 255, 0.12);
    backdrop-filter: blur(16px);
  }

  .workspace-header h1,
  .workspace-panel-head h2,
  .workspace-panel-head h3,
  .topbar h2 {
    font-size: 1.18rem;
    line-height: 1.12;
  }

  .workspace-header-actions,
  .topbar-actions,
  .toolbar,
  .prompt-form {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .workspace-home-action-strip,
  .agent-studio-overview-actions,
  .agent-studio-overview-toolbar,
  .signals-hero-badges,
  #automationScreen .workspace-utility-strip,
  .revenue-module-tabs,
  .revenue-alert-grid {
    display: flex;
    gap: 8px;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 2px;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
  }

  .workspace-home-action-strip::-webkit-scrollbar,
  .agent-studio-overview-actions::-webkit-scrollbar,
  .agent-studio-overview-toolbar::-webkit-scrollbar,
  .signals-hero-badges::-webkit-scrollbar,
  #automationScreen .workspace-utility-strip::-webkit-scrollbar,
  .revenue-module-tabs::-webkit-scrollbar,
  .revenue-alert-grid::-webkit-scrollbar {
    display: none;
  }

  .workspace-home-action-card,
  .agent-studio-overview-actions > *,
  .agent-studio-overview-toolbar > *,
  .signals-hero-badges > *,
  #automationScreen .workspace-utility-pill,
  .revenue-module-tabs > *,
  .revenue-alert-grid > * {
    flex: 0 0 auto;
    min-width: max-content;
    scroll-snap-align: start;
  }

  .workspace-home-action-card {
    min-width: 156px;
  }

  .workspace-home-hero-copy h2,
  .signals-hero-copy h3 {
    font-size: 1.34rem;
    line-height: 1.08;
  }

  .workspace-home-hero-copy .helper-text,
  .signals-hero-copy .helper-text {
    font-size: 0.84rem;
    line-height: 1.42;
  }

  .workspace-header-actions .secondary-button,
  .workspace-header-actions .primary-button,
  .topbar-actions .secondary-button,
  .topbar-actions .primary-button {
    justify-content: center;
  }

  .workspace-panel,
  .info-card,
  .view-panel,
  .summary-panel,
  .workspace-project-card,
  .workspace-home-action-card,
  .workspace-home-glance-card {
    padding: 14px;
    border-radius: 18px;
  }

  .workspace-home-hero,
  .signals-hero-shell,
  #reportsFilterForm,
  #agentScreen .agent-studio-overview-shell,
  #automationScreen .workspace-panel {
    margin-inline: 0;
  }

  #reportsFilterForm {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
  }

  #reportsFilterForm .input-card {
    min-width: 0;
  }

  .revenue-lead-card-top,
  .revenue-lead-card-glance,
  .revenue-lead-card-actions,
  .marketing-panel-head,
  .marketing-review-row,
  .marketing-run-summary {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  .revenue-lead-card-actions,
  .marketing-review-actions.compact,
  .marketing-run-summary-actions {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .workspace-project-grid,
  .workspace-project-stats,
  .workspace-metric-grid,
  .workspace-home-grid,
  .workspace-detail-grid,
  .card-grid,
  .builder-grid,
  .webhook-studio,
  .agent-grid,
  .compact-webhook-form,
  .revenue-intel-workspace,
  .revenue-intel-summary-grid {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 12px;
  }

  .content-list,
  #webhookIndexList,
  #agentRunsList,
  #reportLogsList {
    max-height: none;
    overflow: visible;
  }

  pre,
  textarea,
  input,
  select {
    max-width: 100%;
  }

  .mobile-app-nav {
    position: fixed;
    left: 8px;
    right: 8px;
    bottom: max(6px, env(safe-area-inset-bottom));
    z-index: 80;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 4px;
    padding: 6px;
    min-height: 46px;
    border-radius: 16px;
    border: 1px solid rgba(159, 181, 255, 0.16);
    background: linear-gradient(180deg, rgba(10, 17, 38, 0.97), rgba(6, 11, 27, 0.99));
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.42);
    backdrop-filter: blur(18px);
  }

  body[data-active-screen="loginScreen"] .mobile-app-nav {
    display: none;
  }

  .mobile-app-nav__item {
    display: grid;
    place-items: center;
    align-content: center;
    gap: 2px;
    min-width: 0;
    min-height: 34px;
    color: #99a7cf;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 14px;
    font-weight: 800;
  }

  .mobile-app-nav__item.active {
    color: #f6fbff;
    background: linear-gradient(180deg, rgba(83, 167, 255, 0.16), rgba(141, 103, 255, 0.14));
    border-color: rgba(83, 167, 255, 0.22);
  }

  .mobile-app-nav__label {
    font-size: 0.58rem;
    line-height: 1;
    white-space: nowrap;
  }

  .mobile-app-nav__icon {
    position: relative;
    display: grid;
    place-items: center;
    width: 17px;
    height: 17px;
    color: currentColor;
  }

  .mobile-app-nav__icon::before,
  .mobile-app-nav__icon::after {
    content: "";
    position: absolute;
    box-sizing: border-box;
  }

  .mobile-app-nav__icon-home::before {
    width: 17px;
    height: 17px;
    border: 2px solid currentColor;
    border-radius: 5px;
    transform: rotate(45deg);
  }

  .mobile-app-nav__icon-leads::before {
    width: 18px;
    height: 18px;
    border: 2px solid currentColor;
    border-radius: 50%;
  }

  .mobile-app-nav__icon-leads::after {
    width: 16px;
    height: 2px;
    border-radius: 2px;
    background: currentColor;
    transform: translateY(10px);
  }

  .mobile-app-nav__icon-studio::before {
    width: 18px;
    height: 18px;
    border: 2px solid currentColor;
    border-radius: 6px;
  }

  .mobile-app-nav__icon-studio::after {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: currentColor;
  }

  .mobile-app-nav__icon-engine::before {
    width: 20px;
    height: 14px;
    border: 2px solid currentColor;
    border-radius: 7px;
  }

  .mobile-app-nav__icon-engine::after {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: currentColor;
  }

  .mobile-app-nav__icon-reports::before {
    width: 18px;
    height: 20px;
    border-left: 3px solid currentColor;
    border-bottom: 3px solid currentColor;
  }

  .mobile-app-nav__icon-reports::after {
    width: 12px;
    height: 12px;
    border-top: 3px solid currentColor;
    border-right: 3px solid currentColor;
    transform: translate(3px, -1px);
  }
}

@media (max-width: 380px) {
  .app-shell {
    padding-inline: 8px;
  }

  .mobile-app-nav {
    left: 8px;
    right: 8px;
    gap: 4px;
    padding: 7px;
  }

  .mobile-app-nav__label {
    font-size: 0.6rem;
  }
}

/* Novice-first mobile usability pass */
.mobile-guide-strip {
  display: none;
}

@media (max-width: 720px) {
  html {
    scroll-padding-top: 64px;
  }

  .workspace-main {
    gap: 9px;
  }

  .workspace-header {
    z-index: 70;
    display: flex;
    align-items: center;
    gap: 6px;
    min-height: 52px;
    padding: 7px 8px;
    border-radius: 16px;
  }

  .workspace-route-chip {
    flex: 1 1 auto;
    min-width: 0;
    max-width: 42vw;
    padding: 6px 8px;
    border-radius: 999px;
    font-size: 0.64rem;
    line-height: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .workspace-header .workspace-utility-strip {
    flex: 0 1 auto;
    max-width: 32vw;
    display: flex;
    gap: 4px;
    overflow-x: auto;
    padding: 0;
    scrollbar-width: none;
  }

  .workspace-header .workspace-utility-strip::-webkit-scrollbar {
    display: none;
  }

  .workspace-header .workspace-utility-pill {
    flex: 0 0 auto;
    min-height: 30px;
    padding: 5px 8px;
    border-radius: 999px;
    gap: 0;
  }

  .workspace-header .workspace-utility-pill span {
    display: none;
  }

  .workspace-header .workspace-utility-pill strong {
    font-size: 0.66rem;
    line-height: 1;
    white-space: nowrap;
  }

  .workspace-header-actions {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
  }

  .workspace-release-badge,
  .workspace-health-pill,
  .workspace-logout-button,
  #logoutButtonReports,
  #logoutButtonSecondary,
  .workspace-admin-button {
    display: none !important;
  }

  .workspace-user-copy {
    display: none;
  }

  .workspace-user-pill {
    min-height: 34px;
    min-width: 34px;
    padding: 0;
    border-radius: 999px;
  }

  .workspace-user-avatar {
    width: 30px;
    height: 30px;
  }

  .workspace-header-primary {
    min-height: 34px !important;
    min-width: 44px;
    padding: 0 11px;
    border-radius: 999px;
    font-size: 0;
  }

  .workspace-header-primary::after {
    content: "New";
    font-size: 0.72rem;
    font-weight: 900;
  }

  .mobile-guide-strip {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    border-radius: 14px;
    border: 1px solid rgba(84, 230, 255, 0.14);
    background: rgba(84, 230, 255, 0.07);
  }

  .mobile-guide-strip span {
    padding: 5px 7px;
    border-radius: 999px;
    color: #78efff;
    background: rgba(84, 230, 255, 0.1);
    font-size: 0.62rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    white-space: nowrap;
  }

  .mobile-guide-strip strong {
    min-width: 0;
    color: rgba(238, 246, 255, 0.9);
    font-size: 0.78rem;
    line-height: 1.22;
  }

  .workspace-panel,
  .info-card,
  .view-panel,
  .summary-panel,
  .workspace-project-card,
  .workspace-home-action-card,
  .workspace-home-glance-card,
  .sidebar-card {
    padding: 11px;
    border-radius: 16px;
  }

  .workspace-home-hero-copy h2,
  .signals-hero-copy h3 {
    font-size: 1.12rem;
  }

  .workspace-home-hero-copy .helper-text,
  .workspace-home-spotlight .helper-text,
  .workspace-home-approvals .helper-text,
  .signals-hero-copy .helper-text,
  .panel-head .helper-text,
  .agent-studio-module-copy p,
  .agent-studio-setting-row p {
    display: -webkit-box;
    font-size: 0.78rem;
    line-height: 1.36;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  .workspace-home-action-card {
    min-width: 128px;
    min-height: 70px;
  }

  .workspace-home-action-card span,
  .workspace-home-glance-card span,
  .workspace-home-approval-item small,
  .mapping-meta {
    font-size: 0.68rem;
  }

  .workspace-home-action-card strong,
  .workspace-home-glance-card strong,
  .workspace-home-approval-item strong,
  .agent-studio-module-copy strong {
    font-size: 0.88rem;
    line-height: 1.15;
  }

  .primary-button,
  .secondary-button,
  .nav-button,
  .workspace-nav-button,
  .pill {
    min-height: 38px;
    padding: 8px 10px;
    border-radius: 12px;
    font-size: 0.76rem;
  }

  .panel-head.compact,
  .workspace-home-spotlight-head,
  .workspace-home-approvals-head,
  .marketing-panel-head {
    gap: 8px;
  }

  .panel-head h3,
  .panel-head h4,
  .workspace-home-spotlight-head h3,
  .workspace-home-approvals-head h3,
  .marketing-panel-head h4 {
    font-size: 0.98rem;
    line-height: 1.12;
  }
}

/* Mobile visual density and clarity pass */
@media (max-width: 720px) {
  *,
  *::before,
  *::after {
    max-width: 100%;
    min-width: 0;
  }

  .app-shell {
    padding: 8px 8px 88px;
  }

  .workspace-header {
    min-height: 44px;
    padding: 6px;
    gap: 5px;
    border-radius: 14px;
  }

  .workspace-route-chip {
    max-width: none;
    padding: 6px 8px;
    font-size: 0.62rem;
  }

  .workspace-header .workspace-utility-strip {
    display: none;
  }

  .workspace-user-dropdown {
    position: fixed;
    top: 56px;
    right: 10px;
    left: auto;
    z-index: 120;
    width: min(260px, calc(100vw - 20px));
    max-height: min(420px, calc(100dvh - 76px));
    overflow-y: auto;
  }

  .workspace-user-dropdown-item {
    min-height: 40px;
    padding: 10px 12px;
    font-size: 0.82rem;
  }

  .workspace-header-primary {
    min-height: 32px !important;
    min-width: 40px;
    padding-inline: 10px;
  }

  .workspace-user-pill {
    min-height: 32px;
    min-width: 32px;
  }

  .workspace-user-avatar {
    width: 28px;
    height: 28px;
    font-size: 0.74rem;
  }

  .mobile-guide-strip {
    padding: 7px 9px;
    border-radius: 12px;
  }

  .mobile-guide-strip span {
    padding: 4px 6px;
    font-size: 0.58rem;
  }

  .mobile-guide-strip strong {
    font-size: 0.74rem;
  }

  .eyebrow {
    font-size: 0.58rem;
    letter-spacing: 0.11em;
  }

  .workspace-home-hero-copy .eyebrow,
  .workspace-home-spotlight .eyebrow,
  .workspace-home-approvals .eyebrow,
  .signals-hero-copy .eyebrow,
  .panel-head .eyebrow {
    display: none;
  }

  .workspace-panel,
  .info-card,
  .view-panel,
  .summary-panel,
  .workspace-project-card,
  .workspace-home-action-card,
  .workspace-home-glance-card,
  .sidebar-card,
  .module-panel,
  .agent-workspace-panel,
  .agent-workspace-shell,
  .revenue-intel-workspace,
  .marketing-minimal-hero,
  .marketing-panel,
  .webhook-control-panel,
  .webhook-studio,
  .compact-webhook-form {
    padding: 10px;
    border-radius: 14px;
    overflow-x: hidden;
  }

  .workspace-home-hero-grid,
  .workspace-home-grid,
  .workspace-detail-grid,
  .workspace-home-spotlight,
  .workspace-home-approvals,
  .agent-studio-module-card,
  .agent-studio-setting-row,
  .revenue-lead-card,
  .marketing-run-card,
  .main-grid,
  .workspace-embedded-grid {
    gap: 8px !important;
  }

  .workspace-home-hero-copy h2,
  .signals-hero-copy h3,
  .panel-head h3,
  .panel-head h4 {
    font-size: 0.98rem;
    line-height: 1.12;
  }

  .workspace-home-hero-copy .helper-text,
  .workspace-home-spotlight .helper-text,
  .workspace-home-approvals .helper-text,
  .signals-hero-copy .helper-text,
  .panel-head .helper-text,
  .agent-studio-module-copy p,
  .agent-studio-setting-row p,
  .content-item p,
  .stack-item p {
    font-size: 0.74rem;
    line-height: 1.32;
    -webkit-line-clamp: 1;
  }

  .workspace-home-action-strip,
  .agent-studio-overview-actions,
  .agent-studio-overview-toolbar,
  .signals-hero-badges,
  #automationScreen .workspace-utility-strip,
  .revenue-module-tabs,
  .revenue-alert-grid,
  .builder-tabs,
  .view-switcher,
  .topbar-actions,
  .marketing-panel-head-actions,
  .agent-node-tabs {
    gap: 6px;
    margin-inline: -2px;
    padding-inline: 2px;
    display: flex;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
  }

  .workspace-home-action-strip::-webkit-scrollbar,
  .agent-studio-overview-actions::-webkit-scrollbar,
  .agent-studio-overview-toolbar::-webkit-scrollbar,
  .signals-hero-badges::-webkit-scrollbar,
  #automationScreen .workspace-utility-strip::-webkit-scrollbar,
  .revenue-module-tabs::-webkit-scrollbar,
  .revenue-alert-grid::-webkit-scrollbar,
  .builder-tabs::-webkit-scrollbar,
  .view-switcher::-webkit-scrollbar,
  .topbar-actions::-webkit-scrollbar,
  .marketing-panel-head-actions::-webkit-scrollbar,
  .agent-node-tabs::-webkit-scrollbar {
    display: none;
  }

  .workspace-home-action-card {
    min-width: 118px;
    min-height: 62px;
  }

  .workspace-home-glance-card,
  .workspace-home-approval-item,
  .agent-studio-setting-row,
  .content-item,
  .stack-item {
    padding: 9px;
    border-radius: 12px;
  }

  .workspace-home-action-card span,
  .workspace-home-glance-card span,
  .workspace-home-approval-item small,
  .mapping-meta {
    font-size: 0.64rem;
  }

  .workspace-home-action-card strong,
  .workspace-home-glance-card strong,
  .workspace-home-approval-item strong,
  .agent-studio-module-copy strong,
  .content-item strong,
  .stack-item strong {
    font-size: 0.82rem;
    line-height: 1.12;
  }

  .primary-button,
  .secondary-button,
  .nav-button,
  .workspace-nav-button,
  .pill {
    min-height: 34px;
    padding: 7px 9px;
    border-radius: 11px;
    font-size: 0.72rem;
  }

  .input-card {
    padding: 9px;
    border-radius: 12px;
  }

  .input-card span {
    font-size: 0.68rem;
  }

  input,
  select,
  textarea {
    min-height: 38px;
    font-size: 0.86rem;
  }

  table,
  pre,
  code,
  .table-shell,
  .mapping-table,
  .json-preview,
  .log-output,
  .code-block {
    max-width: 100%;
    overflow-x: auto;
    white-space: pre-wrap;
    word-break: break-word;
  }

  .content-list,
  .summary-list,
  .feed-list,
  .agent-project-browser-list,
  #agentProjectsList,
  #webhookIndexList,
  #agentRunsList,
  #agentOutputsList,
  #reportLogsList,
  #revenueLeadList,
  #revenueTimelineList {
    max-width: 100%;
    overflow-x: hidden;
  }

  .agent-workspace-shell,
  .agent-operations-shell,
  .revenue-intel-workspace,
  .revenue-lead-grid,
  .revenue-pipeline-shell,
  .marketing-run-summary,
  .marketing-review-row,
  .webhook-studio,
  .main-grid,
  .workspace-embedded-grid {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  .modal-card,
  .create-module-modal-card,
  .agent-editor-modal-card,
  .profile-modal-card {
    width: calc(100vw - 16px);
    max-height: calc(100dvh - 20px);
    overflow-y: auto;
  }

  .mobile-app-nav {
    left: 8px;
    right: 8px;
    bottom: max(8px, env(safe-area-inset-bottom));
    gap: 4px;
    min-height: 68px;
    padding: 6px;
    border-radius: 20px;
  }

  .mobile-app-nav__item {
    min-height: 54px;
    gap: 3px;
    border-radius: 15px;
  }

  .mobile-app-nav__icon {
    width: 20px;
    height: 20px;
  }

  .mobile-app-nav__label {
    font-size: 0.54rem;
  }

  .mobile-app-nav__icon-marketing::before {
    width: 18px;
    height: 12px;
    border: 2px solid currentColor;
    border-radius: 5px 8px 8px 5px;
    transform: translateY(-2px);
  }

  .mobile-app-nav__icon-marketing::after {
    width: 8px;
    height: 9px;
    border-left: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: translate(-4px, 8px) rotate(-12deg);
  }

  .mobile-app-nav__icon-revenue::before {
    width: 18px;
    height: 16px;
    border-left: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: translateY(1px);
  }

  .mobile-app-nav__icon-revenue::after {
    width: 15px;
    height: 10px;
    border-top: 2px solid currentColor;
    border-right: 2px solid currentColor;
    transform: translate(2px, -2px) skewY(-22deg);
  }
}

/* Screen-by-screen mobile usability guardrails */
@media (max-width: 720px) {
  #dashboardScreen.active,
  #agentScreen.active,
  #automationScreen.active,
  #reportsScreen.active {
    min-height: auto;
    overflow-x: hidden;
  }

  #dashboardScreen .workspace-home-hero {
    padding: 10px;
  }

  #dashboardScreen .workspace-home-hero-grid,
  #dashboardScreen .workspace-home-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) !important;
  }

  #dashboardScreen .workspace-home-spotlight,
  #dashboardScreen .workspace-home-approvals {
    min-height: 0;
  }

  #dashboardScreen .workspace-home-glance-grid,
  #dashboardScreen .workspace-metric-grid,
  #dashboardScreen .workspace-project-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  #dashboardScreen .workspace-home-approval-list,
  #dashboardScreen .workspace-project-grid {
    display: grid;
    gap: 8px;
  }

  #agentScreen .agent-workspace-panel {
    padding: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
  }

  #agentScreen .agent-studio-overview-shell,
  #agentScreen .agent-workspace-shell,
  #agentScreen .agent-center-stage,
  #agentScreen .agent-side-rail,
  #agentScreen .agent-output-rail,
  #agentScreen .agent-operations-shell,
  #agentScreen .agent-review-panel,
  #agentScreen .agent-queue-panel,
  #agentScreen .agent-workflow-panel,
  #agentScreen .marketing-published-panel {
    width: 100%;
    max-width: 100%;
  }

  #agentScreen .agent-side-rail,
  #agentScreen .agent-output-rail {
    display: none;
  }

  #agentScreen .agent-project-stage,
  #agentScreen #agentProjectStage,
  #agentScreen #marketingMinimalHero,
  #agentScreen #agentCadencePanel,
  #agentScreen #marketingFrequencyCard,
  #agentScreen .agent-review-panel,
  #agentScreen .agent-queue-panel,
  #agentScreen .agent-workflow-panel,
  #agentScreen .marketing-published-panel {
    padding: 10px;
    border-radius: 14px;
  }

  #agentScreen .marketing-minimal-hero {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  #agentScreen .marketing-minimal-hero-meta,
  #agentScreen .marketing-minimal-hero-actions,
  #agentScreen .marketing-run-stage-strip,
  #agentScreen .marketing-review-actions.compact,
  #agentScreen .agent-queue-empty-actions {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    scrollbar-width: none;
  }

  #agentScreen .marketing-minimal-hero-meta::-webkit-scrollbar,
  #agentScreen .marketing-minimal-hero-actions::-webkit-scrollbar,
  #agentScreen .marketing-run-stage-strip::-webkit-scrollbar,
  #agentScreen .marketing-review-actions.compact::-webkit-scrollbar,
  #agentScreen .agent-queue-empty-actions::-webkit-scrollbar {
    display: none;
  }

  #agentScreen .marketing-minimal-hero-actions .primary-button,
  #agentScreen .marketing-minimal-hero-actions .secondary-button,
  #agentScreen .marketing-review-actions.compact .primary-button,
  #agentScreen .marketing-review-actions.compact .secondary-button,
  #agentScreen .agent-queue-empty-actions .primary-button,
  #agentScreen .agent-queue-empty-actions .secondary-button {
    flex: 0 0 auto;
  }

  #agentScreen .marketing-run-summary,
  #agentScreen .marketing-review-row,
  #agentScreen .revenue-lead-card-top,
  #agentScreen .revenue-lead-card-glance,
  #agentScreen .revenue-lead-card-actions,
  #agentScreen .revenue-intel-summary-grid,
  #agentScreen .revenue-lead-grid,
  #agentScreen .revenue-pipeline-shell {
    display: grid;
    grid-template-columns: minmax(0, 1fr) !important;
  }

  #agentScreen .revenue-module-tabs {
    position: sticky;
    top: 54px;
    z-index: 50;
    padding: 6px 0;
    background: rgba(5, 10, 24, 0.92);
    backdrop-filter: blur(14px);
  }

  #agentScreen .revenue-board,
  #agentScreen .revenue-pipeline-board,
  #agentScreen .revenue-board-columns {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(240px, 82vw);
    overflow-x: auto;
    gap: 8px;
    padding-bottom: 6px;
    scroll-snap-type: x proximity;
  }

  #agentScreen .revenue-board > *,
  #agentScreen .revenue-pipeline-board > *,
  #agentScreen .revenue-board-columns > * {
    scroll-snap-align: start;
  }

  #automationScreen .workspace-aux-panel {
    padding: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
  }

  #automationScreen .workspace-embedded-grid {
    display: flex;
    flex-direction: column;
  }

  #automationScreen .sidebar {
    order: -1;
    width: 100%;
  }

  #automationScreen .sidebar .summary-list,
  #automationScreen .automation-side-notes {
    display: none;
  }

  #automationScreen .sidebar-card {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    padding: 8px;
    scrollbar-width: none;
  }

  #automationScreen .sidebar-card::-webkit-scrollbar {
    display: none;
  }

  #automationScreen .sidebar-card .panel-head {
    display: none;
  }

  #automationScreen .sidebar-card .nav-button {
    flex: 0 0 auto;
  }

  #automationScreen .content,
  #automationScreen .view-panel,
  #automationScreen .webhook-control-panel,
  #automationScreen .webhook-studio,
  #automationScreen .compact-webhook-form {
    width: 100%;
    max-width: 100%;
  }

  #automationScreen .compact-webhook-actions,
  #automationScreen .topbar-actions {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    scrollbar-width: none;
  }

  #automationScreen .compact-webhook-actions::-webkit-scrollbar,
  #automationScreen .topbar-actions::-webkit-scrollbar {
    display: none;
  }

  #reportsScreen .workspace-aux-panel {
    padding: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
  }

  #reportsScreen .signals-hero-shell {
    display: grid;
    grid-template-columns: minmax(0, 1fr) !important;
    padding: 10px;
  }

  #reportsScreen .signals-hero-badges {
    justify-content: flex-start;
  }

  #reportsScreen #reportsFilterForm {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  #reportsScreen #reportsFilterForm .info-card {
    grid-column: 1 / -1;
  }

  #reportsScreen #reportLogsList,
  #reportsScreen .report-list,
  #reportsScreen .activity-list {
    display: grid;
    gap: 8px;
  }

  .json-modal-card,
  .endpoint-modal-card,
  .danger-modal-card,
  .profile-modal-card,
  .create-module-modal-card,
  .agent-editor-modal-card,
  .marketing-auth-modal-card,
  .marketing-preview-modal-card,
  .recent-published-modal-card,
  .revenue-deal-modal-card,
  .workspace-utility-modal-card {
    width: calc(100vw - 16px) !important;
    max-width: calc(100vw - 16px) !important;
    max-height: calc(100dvh - 16px);
    overflow-y: auto;
  }

  .agent-editor-modal-grid,
  .profile-form,
  .create-module-form,
  .card-grid,
  .builder-grid,
  .agent-grid,
  .compact-webhook-form {
    grid-template-columns: minmax(0, 1fr) !important;
  }
}

/* World-class mobile refinement pass */
@media (max-width: 720px) {
  body {
    overscroll-behavior-y: contain;
    -webkit-tap-highlight-color: transparent;
  }

  .app-shell {
    min-height: 100dvh;
  }

  .workspace-header {
    box-shadow:
      0 12px 28px rgba(0, 0, 0, 0.28),
      inset 0 1px 0 rgba(255, 255, 255, 0.06);
  }

  .workspace-route-chip {
    color: rgba(238, 246, 255, 0.9);
    background: rgba(255, 255, 255, 0.055);
    border-color: rgba(159, 181, 255, 0.1);
  }

  .workspace-user-dropdown {
    top: auto;
    right: 8px;
    bottom: calc(84px + env(safe-area-inset-bottom));
    left: 8px;
    width: auto;
    max-height: min(360px, calc(100dvh - 126px));
    padding: 8px;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(14, 22, 45, 0.98), rgba(8, 13, 30, 0.99));
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.56);
  }

  .workspace-user-dropdown-item {
    justify-content: flex-start;
    border-radius: 12px;
  }

  .mobile-guide-strip {
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  }

  .workspace-panel,
  .info-card,
  .view-panel,
  .summary-panel,
  .module-panel,
  .content-item,
  .stack-item,
  .input-card {
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.045);
  }

  .stack-item:only-child,
  .webhook-empty-state,
  .automation-empty-callout,
  .embedded-empty,
  .embedded-empty-inline,
  .revenue-board-empty,
  .marketing-queue-empty,
  .marketing-review-empty,
  .marketing-published-empty {
    display: grid;
    gap: 7px;
    padding: 14px;
    min-height: 86px;
    align-content: center;
    border-radius: 14px;
    color: rgba(224, 234, 255, 0.82);
    border: 1px dashed rgba(126, 239, 255, 0.22);
    background:
      linear-gradient(180deg, rgba(84, 230, 255, 0.075), rgba(255, 255, 255, 0.028));
  }

  .stack-item:only-child strong,
  .webhook-empty-state strong,
  .automation-empty-callout strong,
  .revenue-board-empty strong,
  .marketing-queue-empty strong,
  .marketing-review-empty strong,
  .marketing-published-empty strong {
    color: #f6fbff;
  }

  button,
  .primary-button,
  .secondary-button,
  .nav-button,
  .workspace-nav-button,
  .mobile-app-nav__item {
    touch-action: manipulation;
  }

  button:active,
  .primary-button:active,
  .secondary-button:active,
  .nav-button:active,
  .workspace-nav-button:active,
  .mobile-app-nav__item:active {
    transform: scale(0.98);
  }

  button:focus-visible,
  input:focus-visible,
  select:focus-visible,
  textarea:focus-visible,
  .mobile-app-nav__item:focus-visible {
    outline: 2px solid rgba(126, 239, 255, 0.76);
    outline-offset: 2px;
  }

  .mobile-app-nav {
    min-height: 72px;
    border-radius: 22px;
    border-color: rgba(126, 239, 255, 0.18);
    box-shadow:
      0 22px 64px rgba(0, 0, 0, 0.58),
      inset 0 1px 0 rgba(255, 255, 255, 0.07);
  }

  .mobile-app-nav__item {
    position: relative;
    isolation: isolate;
  }

  .mobile-app-nav__item.active::before {
    content: "";
    position: absolute;
    top: 5px;
    width: 18px;
    height: 3px;
    border-radius: 999px;
    background: #7eefff;
    box-shadow: 0 0 16px rgba(126, 239, 255, 0.72);
  }

  .mobile-app-nav__item.active {
    color: #ffffff;
    background:
      radial-gradient(circle at 50% 0%, rgba(126, 239, 255, 0.18), transparent 44%),
      linear-gradient(180deg, rgba(83, 167, 255, 0.18), rgba(141, 103, 255, 0.12));
  }

  .mobile-app-nav__label {
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  #dashboardScreen .workspace-home-action-strip {
    padding-block: 2px 4px;
  }

  #dashboardScreen .workspace-home-action-card {
    border-color: rgba(126, 239, 255, 0.12);
  }

  #agentScreen .marketing-minimal-hero-copy h3,
  #agentScreen .agent-project-stage-head h3,
  #agentScreen .revenue-hero h3 {
    font-size: 1rem;
    line-height: 1.12;
  }

  #agentScreen .marketing-minimal-hero-meta > *,
  #agentScreen .revenue-module-tabs > *,
  #automationScreen .sidebar-card .nav-button,
  #automationScreen .compact-webhook-actions > *,
  #reportsScreen .signals-hero-badges > * {
    flex: 0 0 auto;
  }

  #agentScreen .revenue-lead-card,
  #agentScreen .marketing-run-card,
  #agentScreen .marketing-review-row,
  #automationScreen .webhook-card,
  #reportsScreen #reportLogsList > * {
    contain: layout paint;
  }

  #reportsScreen #reportsFilterForm .primary-button {
    width: 100%;
  }
}

@media (max-width: 380px) {
  #reportsScreen #reportsFilterForm,
  #dashboardScreen .workspace-home-glance-grid,
  #dashboardScreen .workspace-metric-grid,
  #dashboardScreen .workspace-project-stats {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  .mobile-app-nav__label {
    font-size: 0.5rem;
  }

  .mobile-app-nav__item {
    min-height: 52px;
  }

  .mobile-guide-strip {
    grid-template-columns: minmax(0, 1fr);
  }

  .mobile-guide-strip span {
    width: max-content;
  }
}

/* Mobile premium polish pass */
@media (max-width: 720px) {
  .screen.active {
    animation: mobileScreenIn 180ms ease-out both;
  }

  @keyframes mobileScreenIn {
    from {
      opacity: 0.88;
      transform: translateY(4px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }

  .workspace-main::after {
    content: "";
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    height: 112px;
    pointer-events: none;
    z-index: 68;
    background: linear-gradient(180deg, transparent, rgba(2, 7, 18, 0.84));
  }

  body[data-active-screen="loginScreen"] .workspace-main::after {
    display: none;
  }

  .workspace-header {
    top: max(6px, env(safe-area-inset-top));
  }

  .mobile-guide-strip {
    position: relative;
    overflow: hidden;
  }

  .mobile-guide-strip::after {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 3px;
    background: linear-gradient(180deg, #7eefff, #8d67ff);
  }

  .workspace-home-action-strip,
  .agent-studio-overview-actions,
  .agent-studio-overview-toolbar,
  .signals-hero-badges,
  #automationScreen .workspace-utility-strip,
  .revenue-module-tabs,
  .revenue-alert-grid,
  .builder-tabs,
  .view-switcher,
  .topbar-actions,
  .marketing-panel-head-actions,
  .agent-node-tabs,
  #automationScreen .sidebar-card,
  #agentScreen .marketing-minimal-hero-actions,
  #agentScreen .marketing-run-stage-strip,
  #agentScreen .marketing-review-actions.compact {
    mask-image: linear-gradient(90deg, #000 0, #000 calc(100% - 22px), transparent);
  }

  .workspace-home-action-strip > *,
  .agent-studio-overview-actions > *,
  .agent-studio-overview-toolbar > *,
  .signals-hero-badges > *,
  .revenue-module-tabs > *,
  #automationScreen .sidebar-card > *,
  #automationScreen .compact-webhook-actions > *,
  #agentScreen .marketing-minimal-hero-actions > *,
  #agentScreen .marketing-review-actions.compact > * {
    scroll-snap-align: start;
  }

  .workspace-panel,
  .module-panel,
  .info-card,
  .content-item,
  .stack-item,
  .input-card {
    transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
  }

  .content-item:active,
  .stack-item:active,
  .workspace-home-action-card:active,
  .workspace-home-approval-item:active,
  .agent-studio-module-card:active,
  .revenue-lead-card:active,
  .marketing-run-card:active {
    transform: scale(0.992);
    border-color: rgba(126, 239, 255, 0.24);
  }

  .primary-button {
    box-shadow: 0 10px 22px rgba(74, 144, 255, 0.18);
  }

  .workspace-header-primary {
    box-shadow: none;
  }

  #dashboardScreen .workspace-home-spotlight-head,
  #dashboardScreen .workspace-home-approvals-head,
  #agentScreen .panel-head.compact,
  #automationScreen .topbar,
  #reportsScreen .panel-head {
    align-items: start;
  }

  #dashboardScreen .workspace-home-focus-badge,
  #workspaceHomeFocusBadge,
  #workspaceHomeApprovalCount,
  #agentStudioOverviewCount,
  #agentProjectCount,
  #reportHeroBadge,
  #reportHeroMeta {
    width: max-content;
    max-width: 100%;
  }

  #automationScreen .sidebar-card {
    position: sticky;
    top: 54px;
    z-index: 48;
    background: rgba(5, 10, 24, 0.92);
    backdrop-filter: blur(14px);
  }

  #reportsScreen .signals-hero-shell,
  #dashboardScreen .workspace-home-hero,
  #agentScreen #marketingMinimalHero,
  #agentScreen .agent-project-stage {
    border-color: rgba(126, 239, 255, 0.1);
  }

  .json-modal-card::before,
  .endpoint-modal-card::before,
  .profile-modal-card::before,
  .create-module-modal-card::before,
  .agent-editor-modal-card::before {
    content: "";
    display: block;
    width: 42px;
    height: 4px;
    margin: 0 auto 10px;
    border-radius: 999px;
    background: rgba(216, 226, 255, 0.28);
  }

  .modal-actions,
  .register-actions,
  .danger-actions {
    position: sticky;
    bottom: -1px;
    z-index: 5;
    padding-top: 8px;
    background: linear-gradient(180deg, transparent, rgba(8, 13, 30, 0.98) 28%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .screen.active {
    animation: none;
  }

  .workspace-panel,
  .module-panel,
  .info-card,
  .content-item,
  .stack-item,
  .input-card,
  button {
    transition: none !important;
  }
}

/* Stable SVG mobile navigation */
@media (max-width: 720px) {
  .mobile-app-nav {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    min-height: 46px;
  }

  .mobile-app-nav__icon::before,
  .mobile-app-nav__icon::after {
    display: none !important;
  }

  .mobile-app-nav__icon {
    width: 17px;
    height: 17px;
  }

  .mobile-app-nav__icon svg {
    display: block;
    width: 100%;
    height: 100%;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
  }

  .mobile-app-nav__item {
    color: rgba(193, 206, 241, 0.82);
    background: transparent;
  }

  .mobile-app-nav__item.active {
    color: #ffffff;
    background: rgba(126, 239, 255, 0.1);
    border-color: rgba(126, 239, 255, 0.22);
  }

  .mobile-app-nav__item.active .mobile-app-nav__icon {
    color: #7eefff;
  }

  .mobile-app-nav__item.active::before {
    top: 2px;
  }
}

/* Mobile stability guardrails: keep Studio controls inside the viewport and defer to page scroll. */
@media (max-width: 900px) {
  .screen.active,
  .workspace-panel,
  .module-panel,
  .info-card,
  .content-item,
  .stack-item,
  button {
    animation: none !important;
    transition-duration: 0.01ms !important;
  }

  .workspace-header {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 8px;
    overflow: visible;
  }

  .workspace-header-actions {
    width: 100%;
    min-width: 0;
    display: grid !important;
    grid-template-columns: repeat(auto-fit, minmax(0, 1fr));
    gap: 6px;
  }

  .workspace-header .primary-button,
  .workspace-header .secondary-button,
  .workspace-user-pill {
    width: 100%;
    min-width: 0;
    max-width: 100%;
  }

  #agentScreen,
  #agentScreen * {
    max-width: 100%;
  }

  #agentScreen .workspace-header,
  #agentScreen .agent-studio-overview-shell .panel-head.compact {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 8px;
    align-items: stretch;
    overflow: visible;
  }

  #agentScreen .workspace-utility-strip {
    width: 100%;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 6px;
    overflow: visible;
    min-width: 0;
  }

  #agentScreen .workspace-utility-pill,
  #agentScreen .agent-studio-mini-stat,
  #agentScreen .agent-studio-overview-actions .pill {
    min-width: 0;
    width: 100%;
    padding-inline: 6px;
  }

  #agentScreen .workspace-utility-pill span,
  #agentScreen .agent-studio-mini-stat span {
    letter-spacing: 0.06em;
  }

  #agentScreen .workspace-header-actions,
  #agentScreen .agent-studio-overview-actions {
    width: 100%;
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    justify-content: stretch;
    gap: 6px;
    min-width: 0;
  }

  #agentScreen .workspace-header-actions {
    display: none !important;
  }

  #agentScreen .agent-studio-overview-actions {
    grid-template-columns: minmax(0, 0.85fr) minmax(0, 2.15fr);
  }

  #agentScreen .agent-studio-overview-mini-stats {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
    min-width: 0;
    width: 100%;
  }

  #agentScreen .agent-studio-overview-shell .panel-head h4 {
    font-size: 1.1rem;
    line-height: 1.15;
  }

  #agentScreen .workspace-header-primary,
  #agentScreen .workspace-header .primary-button,
  #agentScreen .workspace-header .secondary-button,
  #agentScreen #agentStudioCreateModuleButton {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    min-height: 34px;
    padding-inline: 8px;
    white-space: normal;
    line-height: 1.15;
  }

  #agentScreen #agentStudioCreateModuleButton {
    grid-column: 1 / -1;
  }

  #agentScreen .agent-studio-settings-list,
  #agentScreen .agent-studio-module-catalog {
    grid-template-columns: minmax(0, 1fr) !important;
    width: 100%;
    min-width: 0 !important;
    overflow: visible;
  }

  #agentScreen .agent-studio-overview-toolbar {
    min-width: 0 !important;
    width: 100%;
    overflow: visible !important;
  }

  #agentScreen .agent-studio-setting-row,
  #agentScreen .agent-studio-module-card,
  #agentScreen .agent-studio-catalog-panel--full {
    min-width: 0;
    width: 100%;
    overflow: visible !important;
  }

  #agentScreen .agent-studio-setting-row {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(76px, 104px);
    gap: 8px;
    align-items: center;
  }

  #agentScreen .agent-studio-setting-row .pill {
    justify-self: stretch;
    min-width: 0;
    max-width: 104px;
    padding-inline: 8px;
    text-align: center;
  }

  #agentScreen .agent-studio-setting-row-head,
  #agentScreen .agent-studio-module-head,
  #agentScreen .agent-studio-module-foot,
  #agentScreen .agent-studio-module-summary-row {
    min-width: 0;
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Mobile click-through hardening: no controls under the nav, no horizontal tab spill. */
@media (max-width: 720px) {
  html {
    scroll-padding-bottom: 132px;
  }

  .app-shell {
    padding-bottom: calc(148px + env(safe-area-inset-bottom, 0px)) !important;
  }

  .screen.active::after {
    content: "";
    display: block;
    height: 128px;
  }

  button,
  a,
  input,
  select,
  textarea,
  .primary-button,
  .secondary-button,
  .nav-button {
    scroll-margin-bottom: 140px;
  }

  #automationScreen .workspace-utility-strip,
  #automationScreen .toolbar,
  #automationScreen .sidebar-card:first-child {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 8px;
    overflow: visible !important;
  }

  #automationScreen .workspace-utility-pill,
  #automationScreen .automation-view-pill,
  #automationScreen .automation-status-pill,
  #automationScreen .nav-button {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
  }

  #automationScreen .workspace-header-actions,
  #automationScreen .workspace-header-primary,
  #automationScreen .workspace-header .secondary-button {
    min-width: 0 !important;
    max-width: 100% !important;
  }

  .workspace-panel:last-child,
  .view-panel.active:last-child,
  .content > :last-child,
  .workspace-main > :last-child {
    margin-bottom: 132px;
  }

  .agent-command-actions,
  .agent-queue-empty-actions,
  .marketing-minimal-hero-actions,
  .builder-tabs,
  #reportsFilterForm,
  .onboarding-flow-actions {
    margin-bottom: 72px;
  }

  .agent-command-actions,
  .agent-queue-empty-actions,
  .marketing-minimal-hero-actions {
    transform: translateY(-28px);
  }
}

/* Final mobile nav compactness and action safety for click-through use. */
@media (max-width: 720px) {
  .mobile-app-nav {
    min-height: 36px !important;
    padding: 4px !important;
    bottom: max(4px, env(safe-area-inset-bottom)) !important;
    border-radius: 14px !important;
  }

  .mobile-app-nav__item {
    min-height: 28px !important;
    gap: 1px !important;
    border-radius: 10px !important;
  }

  .mobile-app-nav__icon {
    width: 14px !important;
    height: 14px !important;
  }

  .mobile-app-nav__label {
    font-size: 0.52rem !important;
  }

  .mobile-app-nav__item.active::before {
    display: none !important;
  }

  .agent-command-actions,
  .agent-queue-empty-actions,
  .marketing-minimal-hero-actions {
    transform: translateY(-60px) !important;
  }

  .builder-tabs {
    transform: translateY(-86px) !important;
    margin-bottom: -72px !important;
  }
}

/* Mobile visual pass: keep active actions above the bottom rail and reduce tap ambiguity. */
@media (max-width: 720px) {
  #agentScreen .agent-studio-overview-actions {
    transform: translateY(-52px) !important;
    margin-bottom: -36px !important;
  }

  #agentScreen .agent-studio-overview-actions .secondary-button,
  #agentScreen .agent-studio-overview-actions .primary-button {
    min-height: 34px !important;
    padding: 7px 9px !important;
  }

  #automationScreen .builder-tabs {
    min-height: 40px !important;
    align-items: center !important;
    transform: translateY(-104px) !important;
    margin-bottom: -92px !important;
  }

  #automationScreen .builder-tab {
    min-height: 34px !important;
    padding: 7px 9px !important;
    font-size: 0.7rem !important;
    line-height: 1.1 !important;
  }

  #reportsFilterForm {
    margin-bottom: 96px !important;
  }

  body[data-active-screen="agentScreen"] .mobile-app-nav,
  body[data-active-screen="automationScreen"] .mobile-app-nav,
  body[data-active-screen="reportsScreen"] .mobile-app-nav {
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.38);
  }
}

/* Final mobile click-through guardrails after route testing. */
@media (max-width: 720px) {
  #agentScreen .agent-command-actions {
    transform: translateY(-110px) !important;
    margin-bottom: -92px !important;
  }

  #agentScreen .agent-command-actions .secondary-button,
  #agentScreen .agent-command-actions .primary-button {
    min-height: 34px !important;
    padding: 7px 9px !important;
  }

  #automationScreen .sidebar-card {
    position: static !important;
    top: auto !important;
    z-index: auto !important;
  }
}

/* Mobile usability pass v27: larger navigation, smoother page scroll, lighter copy density. */
@media (max-width: 720px) {
  html,
  body {
    height: auto !important;
    min-height: 100% !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
  }

  body.viewport-locked {
    position: static !important;
    overflow-y: auto !important;
    touch-action: pan-y !important;
  }

  .app-shell {
    height: auto !important;
    min-height: 100dvh !important;
    overflow: visible !important;
    padding-bottom: calc(172px + env(safe-area-inset-bottom, 0px)) !important;
  }

  .screen.active {
    min-height: auto !important;
    overflow: visible !important;
  }

  .screen.active::after {
    height: 158px !important;
  }

  .workspace-main::after {
    height: 132px !important;
  }

  .mobile-app-nav {
    min-height: 54px !important;
    padding: 6px !important;
    bottom: max(6px, env(safe-area-inset-bottom)) !important;
    border-radius: 18px !important;
    gap: 4px !important;
  }

  .mobile-app-nav__item {
    min-height: 42px !important;
    gap: 3px !important;
    border-radius: 13px !important;
    padding: 5px 2px !important;
  }

  .mobile-app-nav__icon {
    width: 21px !important;
    height: 21px !important;
  }

  .mobile-app-nav__label {
    font-size: 0.68rem !important;
    font-weight: 800 !important;
    line-height: 1 !important;
  }

  button,
  a,
  input,
  select,
  textarea,
  .primary-button,
  .secondary-button,
  .nav-button {
    scroll-margin-bottom: 176px !important;
  }

  .workspace-panel:last-child,
  .view-panel.active:last-child,
  .content > :last-child,
  .workspace-main > :last-child {
    margin-bottom: 164px !important;
  }

  body:not([data-active-screen="loginScreen"]) .workspace-header .helper-text,
  body:not([data-active-screen="loginScreen"]) .workspace-panel-head .helper-text,
  body:not([data-active-screen="loginScreen"]) .panel-head .helper-text,
  body:not([data-active-screen="loginScreen"]) .topbar .helper-text,
  body:not([data-active-screen="loginScreen"]) .signals-hero-copy .helper-text,
  body:not([data-active-screen="loginScreen"]) .workspace-home-hero-copy .helper-text,
  body:not([data-active-screen="loginScreen"]) .marketing-minimal-hero-copy .helper-text,
  body:not([data-active-screen="loginScreen"]) .revenue-hero .helper-text {
    display: none !important;
  }

  body:not([data-active-screen="loginScreen"]) .workspace-panel,
  body:not([data-active-screen="loginScreen"]) .module-panel,
  body:not([data-active-screen="loginScreen"]) .info-card,
  body:not([data-active-screen="loginScreen"]) .content-item,
  body:not([data-active-screen="loginScreen"]) .stack-item,
  body:not([data-active-screen="loginScreen"]) .input-card {
    padding-block: 10px !important;
  }

  body:not([data-active-screen="loginScreen"]) .workspace-panel h2,
  body:not([data-active-screen="loginScreen"]) .workspace-panel h3,
  body:not([data-active-screen="loginScreen"]) .module-panel h3,
  body:not([data-active-screen="loginScreen"]) .module-panel h4,
  body:not([data-active-screen="loginScreen"]) .panel-head h3,
  body:not([data-active-screen="loginScreen"]) .panel-head h4 {
    display: -webkit-box !important;
    overflow: hidden !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
  }

  body:not([data-active-screen="loginScreen"]) .content-item p,
  body:not([data-active-screen="loginScreen"]) .stack-item p,
  body:not([data-active-screen="loginScreen"]) .agent-studio-module-copy p,
  body:not([data-active-screen="loginScreen"]) .agent-studio-setting-row p,
  body:not([data-active-screen="loginScreen"]) .marketing-run-card p,
  body:not([data-active-screen="loginScreen"]) .revenue-lead-card p,
  body:not([data-active-screen="loginScreen"]) .webhook-card p {
    display: none !important;
  }

  .mobile-guide-strip {
    padding: 9px 10px !important;
    gap: 6px !important;
  }

  .mobile-guide-strip strong {
    display: -webkit-box !important;
    overflow: hidden !important;
    -webkit-line-clamp: 1 !important;
    -webkit-box-orient: vertical !important;
  }

  .agent-command-actions,
  .agent-queue-empty-actions,
  .marketing-minimal-hero-actions,
  .builder-tabs,
  #reportsFilterForm,
  .onboarding-flow-actions {
    margin-bottom: 104px !important;
  }

  #agentScreen .agent-command-actions {
    transform: translateY(-92px) !important;
    margin-bottom: -60px !important;
  }
}

/* Mobile marketing project pass v29: make the project screen scrollable, visual, and action-first. */
@media (max-width: 720px) {
  #agentScreen.marketing-minimal-mode .workspace-main,
  #agentScreen.marketing-minimal-mode .agent-center-stage,
  #agentScreen.marketing-minimal-mode .agent-workspace-shell,
  #agentScreen.marketing-minimal-mode #agentProjectStage,
  #agentScreen.marketing-minimal-mode .agent-operations-shell {
    overflow: visible !important;
    max-height: none !important;
  }

  #agentScreen.marketing-minimal-mode .marketing-minimal-hero {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 10px !important;
    padding: 12px !important;
    border-radius: 18px !important;
  }

  #agentScreen.marketing-minimal-mode .marketing-minimal-hero.hidden {
    display: none !important;
  }

  #agentScreen.marketing-minimal-mode .marketing-minimal-hero-copy {
    display: grid;
    gap: 5px;
  }

  #agentScreen.marketing-minimal-mode .marketing-minimal-hero-copy .eyebrow,
  #agentScreen.marketing-minimal-mode .marketing-minimal-hero-copy .helper-text {
    display: none !important;
  }

  #agentScreen.marketing-minimal-mode .marketing-minimal-hero-copy h3 {
    font-size: 1rem !important;
    line-height: 1.12 !important;
  }

  #agentScreen.marketing-minimal-mode .marketing-minimal-hero-meta {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 6px !important;
    margin-top: 4px !important;
  }

  #agentScreen.marketing-minimal-mode .marketing-minimal-hero-meta .pill,
  #agentScreen.marketing-minimal-mode .marketing-minimal-hero-meta .secondary-button.compact {
    min-height: 30px !important;
    padding: 6px 7px !important;
    font-size: 0.64rem !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  #agentScreen.marketing-minimal-mode .marketing-minimal-hero-actions {
    position: sticky !important;
    top: max(6px, env(safe-area-inset-top)) !important;
    z-index: 62 !important;
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 7px !important;
    justify-items: stretch !important;
    padding: 8px !important;
    border-radius: 16px !important;
    background: linear-gradient(180deg, rgba(9, 17, 38, 0.98), rgba(5, 10, 24, 0.98)) !important;
    border: 1px solid rgba(126, 239, 255, 0.16) !important;
    box-shadow: 0 18px 36px rgba(0, 0, 0, 0.28) !important;
  }

  #agentScreen.marketing-minimal-mode .marketing-minimal-hero-actions .pill {
    grid-column: 1 / -1;
    justify-content: center;
    width: 100%;
    min-height: 28px !important;
  }

  #agentScreen.marketing-minimal-mode .marketing-minimal-hero-actions .primary-button,
  #agentScreen.marketing-minimal-mode .marketing-minimal-hero-actions .secondary-button {
    width: 100% !important;
    min-width: 0 !important;
    min-height: 42px !important;
    padding: 9px 8px !important;
    font-size: 0.76rem !important;
  }

  #agentScreen.marketing-minimal-mode #agentProjectStage {
    padding: 10px !important;
    border-radius: 18px !important;
  }

  #agentScreen.marketing-minimal-mode .agent-project-stage-head,
  #agentScreen.marketing-minimal-mode .module-overview-copy,
  #agentScreen.marketing-minimal-mode .module-overview-status,
  #agentScreen.marketing-minimal-mode #agentModuleKpiGrid,
  #agentScreen.marketing-minimal-mode #agentPrimaryActionHint {
    display: none !important;
  }

  #agentScreen.marketing-minimal-mode #agentModuleOverviewCard {
    padding: 0 !important;
    gap: 8px !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
  }

  #agentScreen.marketing-minimal-mode .agent-command-actions {
    position: static !important;
    transform: none !important;
    margin: 0 !important;
  }

  #agentScreen.marketing-minimal-mode .agent-command-actions-main {
    display: grid !important;
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr) !important;
    gap: 7px !important;
  }

  #agentScreen.marketing-minimal-mode .agent-command-actions-main #agentOpenSetupBtn {
    grid-column: 1 / -1;
  }

  #agentScreen.marketing-minimal-mode .agent-command-actions-main .primary-button,
  #agentScreen.marketing-minimal-mode .agent-command-actions-main .secondary-button {
    width: 100% !important;
    min-height: 42px !important;
    padding: 9px 8px !important;
    font-size: 0.76rem !important;
  }

  #agentScreen.marketing-minimal-mode .agent-workflow-step-strip {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 6px !important;
  }

  #agentScreen.marketing-minimal-mode .agent-workflow-step-card {
    min-height: 74px !important;
    padding: 8px 6px !important;
    border-radius: 13px !important;
  }

  #agentScreen.marketing-minimal-mode .agent-workflow-step-card span {
    font-size: 0.58rem !important;
  }

  #agentScreen.marketing-minimal-mode .agent-workflow-step-card strong {
    font-size: 0.78rem !important;
    line-height: 1.1 !important;
  }

  #agentScreen.marketing-minimal-mode .agent-workflow-step-card small {
    display: none !important;
  }

  #agentScreen.marketing-minimal-mode .agent-queue-panel,
  #agentScreen.marketing-minimal-mode .agent-review-panel,
  #agentScreen.marketing-minimal-mode .marketing-published-panel {
    padding: 12px !important;
    border-radius: 18px !important;
  }

  #agentScreen.marketing-minimal-mode .marketing-panel-head {
    position: static !important;
    display: grid !important;
    gap: 8px !important;
    padding: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  #agentScreen.marketing-minimal-mode .marketing-panel-head .eyebrow,
  #agentScreen.marketing-minimal-mode .marketing-panel-head .helper-text {
    display: none !important;
  }

  #agentScreen.marketing-minimal-mode .marketing-panel-head h4 {
    font-size: 0.95rem !important;
  }

  #agentScreen.marketing-minimal-mode .marketing-panel-head-actions {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 7px !important;
    justify-content: stretch !important;
  }

  #agentScreen.marketing-minimal-mode .marketing-panel-head-actions .primary-button,
  #agentScreen.marketing-minimal-mode .marketing-panel-head-actions .secondary-button,
  #agentScreen.marketing-minimal-mode .marketing-panel-head-actions .pill {
    width: 100% !important;
    min-height: 34px !important;
    padding: 7px 8px !important;
    font-size: 0.7rem !important;
  }

  #agentScreen.marketing-minimal-mode .marketing-queue-empty {
    min-height: 0 !important;
    padding: 14px !important;
    border-radius: 16px !important;
    gap: 10px !important;
    border-style: solid !important;
  }

  #agentScreen.marketing-minimal-mode .marketing-empty-visual {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
  }

  #agentScreen.marketing-minimal-mode .marketing-empty-visual span {
    display: grid;
    place-items: center;
    min-height: 42px;
    border-radius: 14px;
    color: #051021;
    font-weight: 900;
    background: linear-gradient(135deg, #7eefff, #96ffd9);
  }

  #agentScreen.marketing-minimal-mode .marketing-queue-empty > span {
    font-size: 0.82rem !important;
    line-height: 1.25 !important;
  }

  #agentScreen.marketing-minimal-mode .marketing-queue-empty-summary {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
  }

  #agentScreen.marketing-minimal-mode .marketing-queue-empty-summary span {
    display: grid;
    place-items: center;
    min-height: 28px;
    border-radius: 999px;
    color: #dff8ff;
    background: rgba(126, 239, 255, 0.1);
    font-size: 0.68rem;
    font-weight: 800;
  }

  #agentScreen.marketing-minimal-mode .agent-queue-empty-actions {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr);
    gap: 7px;
    transform: none !important;
    margin: 0 !important;
  }

  #agentScreen.marketing-minimal-mode .agent-queue-empty-actions .primary-button,
  #agentScreen.marketing-minimal-mode .agent-queue-empty-actions .secondary-button {
    width: 100% !important;
    min-height: 42px !important;
    font-size: 0.76rem !important;
  }
}

/* Mobile marketing fallback v30: applies when the project screen renders before marketing mode hydrates. */
@media (max-width: 720px) {
  #agentScreen .workspace-main,
  #agentScreen .agent-center-stage,
  #agentScreen .agent-workspace-shell,
  #agentScreen #agentProjectStage,
  #agentScreen .agent-operations-shell {
    overflow: visible !important;
    max-height: none !important;
  }

  #agentScreen #agentProjectStage {
    padding: 10px !important;
    border-radius: 18px !important;
  }

  #agentScreen .agent-project-stage-head,
  #agentScreen .module-overview-copy,
  #agentScreen .module-overview-status,
  #agentScreen #agentModuleKpiGrid,
  #agentScreen #agentPrimaryActionHint {
    display: none !important;
  }

  #agentScreen #agentModuleOverviewCard {
    padding: 0 !important;
    gap: 8px !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
  }

  #agentScreen .agent-command-actions {
    position: static !important;
    transform: none !important;
    margin: 0 !important;
  }

  #agentScreen .agent-command-actions-main {
    display: grid !important;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) !important;
    gap: 8px !important;
  }

  #agentScreen .agent-command-actions-main #agentOpenSetupBtn {
    grid-column: 1 / -1;
  }

  #agentScreen .agent-command-actions-main .primary-button,
  #agentScreen .agent-command-actions-main .secondary-button {
    width: 100% !important;
    min-height: 44px !important;
    padding: 10px 8px !important;
    font-size: 0.78rem !important;
  }

  #agentScreen .agent-workflow-step-strip {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 6px !important;
  }

  #agentScreen .agent-workflow-step-card {
    min-height: 70px !important;
    padding: 8px 6px !important;
    border-radius: 13px !important;
  }

  #agentScreen .agent-workflow-step-card span {
    font-size: 0.58rem !important;
  }

  #agentScreen .agent-workflow-step-card strong {
    font-size: 0.76rem !important;
    line-height: 1.1 !important;
  }

  #agentScreen .agent-workflow-step-card small {
    display: none !important;
  }

  #agentScreen .agent-queue-panel,
  #agentScreen .agent-review-panel,
  #agentScreen .marketing-published-panel {
    padding: 12px !important;
    border-radius: 18px !important;
    overflow: visible !important;
  }

  #agentScreen .marketing-panel-head {
    position: static !important;
    display: grid !important;
    gap: 8px !important;
    padding: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  #agentScreen .marketing-panel-head .eyebrow,
  #agentScreen .marketing-panel-head .helper-text {
    display: none !important;
  }

  #agentScreen .marketing-panel-head h4 {
    font-size: 0.95rem !important;
    line-height: 1.12 !important;
  }

  #agentScreen .marketing-panel-head-actions {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 7px !important;
    justify-content: stretch !important;
  }

  #agentScreen .marketing-panel-head-actions .primary-button,
  #agentScreen .marketing-panel-head-actions .secondary-button,
  #agentScreen .marketing-panel-head-actions .pill {
    width: 100% !important;
    min-height: 36px !important;
    padding: 7px 8px !important;
    font-size: 0.7rem !important;
  }

  #agentScreen .marketing-queue-empty {
    min-height: 0 !important;
    padding: 14px !important;
    border-radius: 16px !important;
    gap: 10px !important;
    border-style: solid !important;
  }

  #agentScreen .marketing-empty-visual {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
  }

  #agentScreen .marketing-empty-visual span {
    display: grid;
    place-items: center;
    min-height: 42px;
    border-radius: 14px;
    color: #051021;
    font-weight: 900;
    background: linear-gradient(135deg, #7eefff, #96ffd9);
  }

  #agentScreen .marketing-queue-empty > span {
    font-size: 0.82rem !important;
    line-height: 1.25 !important;
  }

  #agentScreen .marketing-queue-empty-summary {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
  }

  #agentScreen .marketing-queue-empty-summary span {
    display: grid;
    place-items: center;
    min-height: 28px;
    border-radius: 999px;
    color: #dff8ff;
    background: rgba(126, 239, 255, 0.1);
    font-size: 0.68rem;
    font-weight: 800;
  }

  #agentScreen .agent-queue-empty-actions {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr);
    gap: 7px;
    transform: none !important;
    margin: 0 !important;
  }

  #agentScreen .agent-queue-empty-actions .primary-button,
  #agentScreen .agent-queue-empty-actions .secondary-button {
    width: 100% !important;
    min-height: 42px !important;
    font-size: 0.76rem !important;
  }

  #agentScreen .agent-studio-module-card {
    gap: 12px !important;
  }

  #agentScreen .agent-studio-module-foot {
    gap: 10px !important;
  }

  #agentScreen .marketing-project-card-actions {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    width: 100%;
  }

  #agentScreen .marketing-project-card-actions .secondary-button:last-child {
    grid-column: auto;
  }

  #agentScreen .marketing-project-card-actions .primary-button,
  #agentScreen .marketing-project-card-actions .secondary-button {
    width: 100%;
    min-height: 44px !important;
    padding: 9px 6px !important;
    font-size: 0.68rem !important;
    white-space: normal !important;
    line-height: 1.05 !important;
  }

  #agentScreen .agent-studio-module-card .agent-studio-module-status span {
    display: -webkit-box !important;
    overflow: hidden !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
  }
}

/* Mobile marketing 10/10 pass v33: focused launcher, lighter cards, faster first action. */
@media (max-width: 720px) {
  body[data-active-screen="agentScreen"] .mobile-guide-strip {
    display: none !important;
  }

  #agentScreen .workspace-header {
    padding: 10px !important;
    border-radius: 18px !important;
  }

  #agentScreen .workspace-route-chip {
    min-height: 42px !important;
    padding: 10px 12px !important;
    border-radius: 999px !important;
    font-size: 0.78rem !important;
    justify-content: center !important;
    text-align: center !important;
  }

  #agentScreen .agent-studio-catalog-panel--full {
    padding: 10px !important;
    gap: 10px !important;
    border-radius: 18px !important;
  }

  #agentScreen .agent-studio-catalog-panel--full > .panel-head {
    position: static !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    gap: 8px !important;
    align-items: center !important;
    padding: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  #agentScreen .agent-studio-catalog-panel--full > .panel-head .eyebrow,
  #agentScreen .agent-studio-catalog-panel--full > .panel-head .helper-text {
    display: none !important;
  }

  #agentScreen .agent-studio-catalog-panel--full > .panel-head h4 {
    font-size: 1.2rem !important;
    line-height: 1 !important;
  }

  #agentScreen #agentStudioOverviewCount {
    min-height: 30px !important;
    padding: 6px 8px !important;
    font-size: 0.68rem !important;
  }

  #agentScreen #agentStudioOverviewStats {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 6px !important;
  }

  #agentScreen #agentStudioOverviewStats .agent-studio-mini-stat {
    min-height: 50px !important;
    padding: 7px 6px !important;
    border-radius: 13px !important;
  }

  #agentScreen #agentStudioOverviewStats .agent-studio-mini-stat span {
    font-size: 0.58rem !important;
  }

  #agentScreen #agentStudioOverviewStats .agent-studio-mini-stat strong {
    font-size: 1rem !important;
  }

  #agentScreen #agentStudioCreateModuleButton {
    min-height: 42px !important;
    border-radius: 14px !important;
    font-size: 0.82rem !important;
  }

  #agentScreen #agentStudioOverviewSettings {
    display: none !important;
  }

  #agentScreen #agentStudioModuleCatalog {
    gap: 10px !important;
    padding-bottom: 132px !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-card {
    min-height: 0 !important;
    padding: 12px !important;
    border-radius: 18px !important;
    gap: 10px !important;
    background:
      radial-gradient(circle at top right, rgba(126, 239, 255, 0.12), transparent 34%),
      linear-gradient(180deg, rgba(38, 47, 91, 0.98), rgba(14, 20, 43, 0.98)) !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-card:not(:first-child) {
    transform: none !important;
    margin-top: 340px !important;
    margin-bottom: 0 !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-head {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 8px !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-title {
    display: grid !important;
    grid-template-columns: 44px minmax(0, 1fr) !important;
    gap: 10px !important;
    align-items: center !important;
  }

  #agentScreen #agentStudioModuleCatalog .project-insight-icon {
    width: 44px !important;
    height: 44px !important;
    border-radius: 14px !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-copy strong {
    font-size: 1.02rem !important;
    line-height: 1.08 !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-copy p {
    display: none !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-actions {
    align-items: stretch !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-actions .pill {
    width: 100% !important;
    min-height: 30px !important;
    justify-content: center !important;
    border-radius: 999px !important;
    font-size: 0.7rem !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-actions .pill.warning {
    color: #ffd3df !important;
    background: rgba(255, 119, 161, 0.12) !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 6px !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-stat:nth-child(n + 3) {
    display: none !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-stat {
    min-height: 48px !important;
    padding: 7px 6px !important;
    border-radius: 12px !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-stat span {
    font-size: 0.55rem !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-stat strong {
    font-size: 0.95rem !important;
    line-height: 1 !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-foot {
    gap: 8px !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-status {
    display: grid !important;
    gap: 3px !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-status strong {
    font-size: 0.78rem !important;
    line-height: 1.1 !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-status span {
    display: none !important;
  }

  #agentScreen #agentStudioModuleCatalog .agent-studio-module-summary-row {
    display: none !important;
  }

  #agentScreen .marketing-project-card-actions {
    grid-template-columns: minmax(0, 1.2fr) repeat(2, minmax(0, 0.9fr)) !important;
    gap: 6px !important;
  }

  #agentScreen .marketing-project-card-actions .primary-button,
  #agentScreen .marketing-project-card-actions .secondary-button {
    min-height: 42px !important;
    border-radius: 13px !important;
    padding: 8px 5px !important;
    font-size: 0.66rem !important;
  }
}

/* Full app mobile usability overhaul v36: app-like first viewports and safer controls. */
@media (max-width: 720px) {
  .mobile-guide-strip {
    display: none !important;
  }

  .workspace-user-pill {
    display: none !important;
  }

  .workspace-header,
  .topbar,
  .workspace-panel-head,
  .panel-head {
    min-width: 0 !important;
  }

  .workspace-header-actions {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 6px !important;
  }

  .workspace-header-actions .primary-button,
  .workspace-header-actions .secondary-button {
    width: 100% !important;
    min-height: 42px !important;
    font-size: 0.8rem !important;
    white-space: normal !important;
  }

  body:not([data-active-screen="loginScreen"]) .workspace-main {
    gap: 10px !important;
  }

  body:not([data-active-screen="loginScreen"]) .workspace-panel,
  body:not([data-active-screen="loginScreen"]) .module-panel,
  body:not([data-active-screen="loginScreen"]) .view-panel,
  body:not([data-active-screen="loginScreen"]) .info-card {
    border-radius: 18px !important;
  }

  body:not([data-active-screen="loginScreen"]) .workspace-panel h2,
  body:not([data-active-screen="loginScreen"]) .workspace-panel h3,
  body:not([data-active-screen="loginScreen"]) .workspace-panel h4 {
    letter-spacing: 0 !important;
  }

  #dashboardScreen .workspace-home-hero {
    padding: 14px !important;
    gap: 10px !important;
  }

  #dashboardScreen .workspace-home-hero-copy h2 {
    font-size: 1.55rem !important;
    line-height: 1.02 !important;
  }

  #dashboardScreen .workspace-home-hero-copy .helper-text,
  #dashboardScreen .workspace-home-spotlight-head .helper-text,
  #dashboardScreen .workspace-home-approvals-head .helper-text {
    display: none !important;
  }

  #dashboardScreen .workspace-home-hero-grid,
  #dashboardScreen .workspace-home-grid {
    gap: 10px !important;
  }

  #dashboardScreen .workspace-home-spotlight,
  #dashboardScreen .workspace-home-approvals,
  #dashboardScreen .workspace-home-command-card {
    padding: 12px !important;
    min-height: 0 !important;
  }

  #dashboardScreen .workspace-home-glance-grid,
  #dashboardScreen .workspace-metric-grid,
  #dashboardScreen .workspace-project-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 8px !important;
  }

  #dashboardScreen .workspace-home-glance-card,
  #dashboardScreen .workspace-metric-card,
  #dashboardScreen .workspace-project-stat {
    min-height: 72px !important;
    padding: 10px !important;
  }

  #automationScreen .workspace-header {
    position: static !important;
  }

  #automationScreen .workspace-header-actions {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  #automationScreen .workspace-utility-strip {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 6px !important;
  }

  #automationScreen .workspace-utility-pill {
    min-height: 44px !important;
    padding: 8px 7px !important;
    border-radius: 14px !important;
  }

  #automationScreen .workspace-utility-pill span {
    font-size: 0.58rem !important;
  }

  #automationScreen .workspace-utility-pill strong {
    font-size: 0.88rem !important;
  }

  #automationScreen #automationHeaderPrimaryButton {
    position: sticky !important;
    top: max(6px, env(safe-area-inset-top)) !important;
    z-index: 62 !important;
    min-height: 48px !important;
    margin: 4px 0 6px !important;
    box-shadow: 0 18px 34px rgba(74, 95, 255, 0.2) !important;
  }

  #automationScreen .view-switcher,
  #automationScreen .builder-tabs,
  #reportsScreen #reportsFilterForm {
    margin-bottom: 132px !important;
  }

  #automationScreen .activity-feed,
  #automationScreen #activityFeed,
  #automationScreen .automation-setup-shell {
    display: none !important;
  }

  #automationScreen #webhookIndexList,
  #automationScreen .webhook-list,
  #automationScreen .stack-list {
    padding-bottom: 180px !important;
  }

  #automationScreen #webhookIndexList > :first-child,
  #automationScreen .webhook-list > :first-child {
    margin-top: 112px !important;
  }

  #reportsScreen .signals-hero-shell {
    padding: 12px !important;
    gap: 10px !important;
  }

  #reportsScreen .signals-hero-copy .helper-text,
  #reportsScreen .panel-head .helper-text {
    display: none !important;
  }

  #reportsScreen #reportsFilterForm {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 8px !important;
  }

  #reportsScreen #reportsFilterForm .primary-button {
    grid-column: 1 / -1 !important;
    min-height: 44px !important;
  }

  #agentScreen .agent-studio-catalog-panel--full > .panel-head,
  #automationScreen .topbar,
  #reportsScreen .panel-head {
    top: auto !important;
  }

  .screen.active::after {
    height: 190px !important;
  }
}

/* Mobile app usability polish v39: remove legacy upward pulls that caused visual collisions. */
@media (max-width: 720px) {
  #agentScreen .agent-studio-catalog-panel--full > .panel-head {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 12px !important;
    min-height: 0 !important;
    align-items: stretch !important;
  }

  #agentScreen .agent-studio-overview-actions {
    position: static !important;
    transform: none !important;
    margin: 0 !important;
    display: grid !important;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 2.1fr) !important;
    align-items: stretch !important;
  }

  #agentScreen #agentStudioOverviewCount,
  #agentScreen #agentStudioOverviewStats,
  #agentScreen #agentStudioCreateModuleButton {
    transform: none !important;
  }

  #agentScreen #agentStudioCreateModuleButton {
    grid-column: 1 / -1 !important;
    margin-top: 2px !important;
  }

  #agentScreen .agent-studio-overview-toolbar {
    display: none !important;
  }

  #automationScreen .builder-tabs {
    transform: none !important;
    margin: 0 0 12px !important;
    min-height: 44px !important;
  }

  #automationScreen #automationHeaderPrimaryButton {
    white-space: normal !important;
    word-break: normal !important;
  }

  .workspace-header-primary::after,
  #automationScreen #automationHeaderPrimaryButton::after {
    content: none !important;
    display: none !important;
  }
}

/* Mobile app usability polish v42: denser reports, cleaner automation, calmer queues. */
@media (max-width: 720px) {
  #reportsScreen .signals-hero-shell {
    padding: 10px !important;
    gap: 8px !important;
  }

  #reportsScreen .signals-hero-shell h3,
  #reportsScreen .signals-hero-copy h3 {
    display: none !important;
  }

  #reportsScreen > .workspace-shell .workspace-main > .panel-head {
    display: none !important;
  }

  #reportsScreen .panel-head > div > h3 {
    display: none !important;
  }

  #reportsScreen .signals-hero-badges {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 8px !important;
  }

  #reportsScreen #reportsFilterForm {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 8px !important;
    padding: 10px !important;
    margin-top: 10px !important;
    margin-bottom: 24px !important;
  }

  #reportsScreen #reportsFilterForm .input-card {
    min-height: 0 !important;
    padding: 9px !important;
    border-radius: 16px !important;
    gap: 6px !important;
  }

  #reportsScreen #reportsFilterForm .input-card span {
    font-size: 0.72rem !important;
  }

  #reportsScreen #reportsFilterForm input,
  #reportsScreen #reportsFilterForm select {
    min-height: 44px !important;
    padding: 0 10px !important;
    border-radius: 14px !important;
    font-size: 0.92rem !important;
  }

  #reportsScreen #reportsFilterForm .info-card {
    grid-column: auto !important;
    min-height: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
  }

  #reportsScreen #reportsFilterForm .primary-button {
    min-height: 64px !important;
    height: 100% !important;
    border-radius: 16px !important;
  }

  #automationScreen #openWebhookCreateBtn {
    display: none !important;
  }

  #automationScreen .workspace-aux-panel .topbar {
    gap: 8px !important;
  }

  #automationScreen .workspace-aux-panel .topbar h3 {
    font-size: 1rem !important;
    line-height: 1.15 !important;
    display: -webkit-box !important;
    -webkit-box-orient: vertical !important;
    -webkit-line-clamp: 2 !important;
    overflow: hidden !important;
  }

  #automationScreen .workspace-aux-panel .topbar-actions .pill {
    width: 100% !important;
    min-height: 38px !important;
  }

  #automationScreen #webhookIndexList > :first-child,
  #automationScreen .webhook-list > :first-child {
    margin-top: 170px !important;
  }

  #dashboardScreen .workspace-home-approval-item strong,
  #dashboardScreen .workspace-command-row strong,
  #dashboardScreen .output-review-card summary strong {
    display: -webkit-box !important;
    -webkit-box-orient: vertical !important;
    -webkit-line-clamp: 2 !important;
    overflow: hidden !important;
    line-height: 1.18 !important;
  }

  #dashboardScreen .workspace-home-approval-item .pill,
  #dashboardScreen .workspace-command-row .pill,
  #dashboardScreen .content-item-meta .pill {
    max-width: 100% !important;
    min-height: 30px !important;
    padding: 6px 9px !important;
    font-size: 0.72rem !important;
  }
}

/* Staging product-truth pass: mobile controls must not obscure operational work. */
@media (max-width: 720px) {
  .app-language-switch {
    top: max(14px, env(safe-area-inset-top)) !important;
    right: max(12px, env(safe-area-inset-right)) !important;
    bottom: auto !important;
    z-index: 95;
    padding: 3px;
  }

  .app-language-switch button {
    width: 34px;
    min-height: 30px;
    font-size: 0.66rem;
  }

  .workspace-header .workspace-route-chip,
  #agentScreen .workspace-route-chip,
  #automationScreen .workspace-route-chip,
  #reportsScreen .workspace-route-chip {
    width: calc(100vw - 112px) !important;
    max-width: calc(100vw - 112px) !important;
    margin-right: auto !important;
  }

  .revenue-module-tabbar {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 6px !important;
    overflow: visible !important;
    width: 100% !important;
    padding: 6px !important;
  }

  .revenue-module-tab {
    min-width: 0 !important;
    width: 100% !important;
    min-height: 48px !important;
    padding: 7px 8px !important;
    gap: 7px !important;
  }

  .revenue-module-tab-copy {
    min-width: 0;
  }

  .revenue-module-tab-copy small {
    display: none;
  }

  .revenue-module-tab-copy strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 0.76rem;
  }
}

/* Final MeshLine OS precedence after legacy workspace rules. */ #dashboardScreen .workspace-utility-strip { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; min-height: 54px; } #dashboardScreen .workspace-utility-pill { min-height: 42px; padding: 6px 9px; } #dashboardScreen .workspace-shell { grid-template-columns: 224px minmax(0, 1fr); gap: 0; overflow: hidden; border: 1px solid rgba(142, 168, 228, 0.16); border-radius: 22px; background: rgba(5, 10, 23, 0.96); box-shadow: 0 32px 100px rgba(0, 0, 0, 0.42); } #dashboardScreen .workspace-sidebar { border: 0; border-right: 1px solid rgba(142, 168, 228, 0.12); border-radius: 0; background: radial-gradient(circle at 24% 0%, rgba(85, 220, 255, 0.08), transparent 24%), rgba(6, 12, 27, 0.98); } #dashboardScreen .workspace-main { gap: 14px; padding: 0 18px 28px; background: radial-gradient(circle at 70% 0%, rgba(90, 140, 255, 0.075), transparent 24%), linear-gradient(180deg, rgba(8, 15, 33, 0.98), rgba(5, 10, 23, 0.98)); } #dashboardScreen .workspace-header { top: 0; min-height: 70px; margin-inline: -18px; padding: 10px 18px; border: 0; border-bottom: 1px solid rgba(142, 168, 228, 0.12); border-radius: 0; background: rgba(7, 13, 29, 0.88); box-shadow: none; backdrop-filter: blur(22px); } #dashboardScreen .workspace-route-chip { border-color: rgba(142, 168, 228, 0.14); color: rgba(226, 235, 255, 0.74); background: rgba(255, 255, 255, 0.035); } #dashboardScreen .workspace-nav-button { min-height: 54px; border: 1px solid transparent; border-radius: 14px; } #dashboardScreen .workspace-nav-button:hover, #dashboardScreen .workspace-nav-button.active { border-color: rgba(85, 220, 255, 0.16); background: linear-gradient(110deg, rgba(85, 220, 255, 0.1), rgba(90, 140, 255, 0.055)); box-shadow: inset 3px 0 0 var(--os-cyan); } #dashboardScreen .workspace-panel { border-color: rgba(142, 168, 228, 0.13); background: rgba(10, 18, 38, 0.76); box-shadow: 0 22px 54px rgba(0, 0, 0, 0.18); } #dashboardScreen .workspace-panel.mesh-os-home { background: radial-gradient(circle at 76% 10%, rgba(90, 140, 255, 0.16), transparent 34%), radial-gradient(circle at 94% 48%, rgba(165, 108, 255, 0.1), transparent 28%), linear-gradient(150deg, rgba(12, 24, 50, 0.96), rgba(7, 14, 31, 0.98)); } #dashboardScreen .workspace-project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; } #dashboardScreen .workspace-project-card { display: grid; gap: 15px; min-height: 350px; padding: 19px; border-color: rgba(142, 168, 228, 0.13); border-radius: 20px; background: radial-gradient(circle at 90% 0%, rgba(90, 140, 255, 0.1), transparent 32%), linear-gradient(150deg, rgba(12, 22, 46, 0.95), rgba(7, 14, 31, 0.96)); box-shadow: 0 20px 46px rgba(0, 0, 0, 0.18); } #dashboardScreen .workspace-project-card:hover, #dashboardScreen .workspace-project-card:focus-visible, #dashboardScreen .workspace-project-card.active { border-color: rgba(85, 220, 255, 0.3); box-shadow: 0 24px 54px rgba(0, 0, 0, 0.24), inset 0 0 36px rgba(85, 220, 255, 0.035); transform: translateY(-3px); } @media (max-width: 960px) { #dashboardScreen .workspace-shell { grid-template-columns: 1fr; } #dashboardScreen .workspace-main { padding-inline: 12px; } #dashboardScreen .workspace-header { margin-inline: -12px; padding-inline: 12px; } #dashboardScreen .workspace-project-grid { grid-template-columns: 1fr; } }
.auth-consent-control {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 0.65rem;
  font-size: 0.82rem;
  line-height: 1.45;
}

.auth-consent-control input {
  width: 1rem;
  height: 1rem;
  margin-top: 0.12rem;
}

.auth-consent-control a {
  color: var(--accent, #45d7ff);
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

.profile-account-summary {
  margin-bottom: 1rem;
  padding: 1rem;
  border: 1px solid rgba(111, 132, 184, 0.24);
  border-radius: 16px;
  background: rgba(34, 49, 82, 0.42);
}

.profile-account-summary .secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}
