Skip to content

Fully autonomous AI Agents system capable of performing complex penetration testing tasks

26.8 KB
Raw Blame
@import 'tailwindcss';
@import 'tw-animate-css';
@plugin '@tailwindcss/typography';

@custom-variant dark (&:is(.dark *));

@font-face {
    font-family: 'Inter Fallback';
    src: local('Arial');
    ascent-override: 90%;
    descent-override: 22.43%;
    line-gap-override: 0%;
    size-adjust: 107.64%;
}

@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('/fonts/inter-regular.woff2') format('woff2');
}

@font-face {
    font-family: 'Inter';
    font-style: italic;
    font-weight: 400;
    font-display: swap;
    src: url('/fonts/inter-italic.woff2') format('woff2');
}

@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url('/fonts/inter-500.woff2') format('woff2');
}

@font-face {
    font-family: 'Inter';
    font-style: italic;
    font-weight: 500;
    font-display: swap;
    src: url('/fonts/inter-500-italic.woff2') format('woff2');
}

@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url('/fonts/inter-600.woff2') format('woff2');
}

@font-face {
    font-family: 'Inter';
    font-style: italic;
    font-weight: 600;
    font-display: swap;
    src: url('/fonts/inter-600-italic.woff2') format('woff2');
}

@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url('/fonts/inter-700.woff2') format('woff2');
}

@font-face {
    font-family: 'Inter';
    font-style: italic;
    font-weight: 700;
    font-display: swap;
    src: url('/fonts/inter-700-italic.woff2') format('woff2');
}

@font-face {
    font-family: 'Roboto Mono';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('/fonts/roboto-mono-regular.woff2') format('woff2');
}

@font-face {
    font-family: 'Roboto Mono';
    font-style: italic;
    font-weight: 400;
    font-display: swap;
    src: url('/fonts/roboto-mono-italic.woff2') format('woff2');
}

@font-face {
    font-family: 'Roboto Mono';
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url('/fonts/roboto-mono-500.woff2') format('woff2');
}

@font-face {
    font-family: 'Roboto Mono';
    font-style: italic;
    font-weight: 500;
    font-display: swap;
    src: url('/fonts/roboto-mono-500-italic.woff2') format('woff2');
}

@font-face {
    font-family: 'Roboto Mono';
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url('/fonts/roboto-mono-600.woff2') format('woff2');
}

@font-face {
    font-family: 'Roboto Mono';
    font-style: italic;
    font-weight: 600;
    font-display: swap;
    src: url('/fonts/roboto-mono-600-italic.woff2') format('woff2');
}

@font-face {
    font-family: 'Roboto Mono';
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url('/fonts/roboto-mono-700.woff2') format('woff2');
}

@font-face {
    font-family: 'Roboto Mono';
    font-style: italic;
    font-weight: 700;
    font-display: swap;
    src: url('/fonts/roboto-mono-700-italic.woff2') format('woff2');
}

@utility container {
    margin-inline: auto;
    padding-inline: 2rem;
    @media (width >= --theme(--breakpoint-sm)) {
        max-width: none;
    }
    @media (width >= 1400px) {
        max-width: 1400px;
    }
}

@theme {
    --animate-logo-spin: logo-spin 10s cubic-bezier(0.5, -0.5, 0.5, 1.25) infinite;
    --animate-roll-reveal: roll-reveal 0.4s cubic-bezier(0.22, 1.28, 0.54, 0.99);
    --animate-slide-left: slide-left 0.3s ease-out;
    --animate-slide-top: slide-top 0.3s ease-out;

    --color-background: var(--background);
    --color-foreground: var(--foreground);
    --color-card: var(--card);
    --color-card-foreground: var(--card-foreground);
    --color-popover: var(--popover);
    --color-popover-foreground: var(--popover-foreground);
    --color-primary: var(--primary);
    --color-primary-foreground: var(--primary-foreground);
    --color-link: var(--link);
    --color-secondary: var(--secondary);
    --color-secondary-foreground: var(--secondary-foreground);
    --color-muted: var(--muted);
    --color-muted-foreground: var(--muted-foreground);
    --color-accent: var(--accent);
    --color-accent-foreground: var(--accent-foreground);
    --color-destructive: var(--destructive);
    --color-destructive-foreground: var(--destructive-foreground);
    --color-border: var(--border);
    --color-input: var(--input);
    --color-ring: var(--ring);
    --color-chart-1: var(--chart-1);
    --color-chart-2: var(--chart-2);
    --color-chart-3: var(--chart-3);
    --color-chart-4: var(--chart-4);
    --color-chart-5: var(--chart-5);
    --color-sidebar: var(--sidebar);
    --color-sidebar-foreground: var(--sidebar-foreground);
    --color-sidebar-primary: var(--sidebar-primary);
    --color-sidebar-primary-foreground: var(--sidebar-primary-foreground);
    --color-sidebar-accent: var(--sidebar-accent);
    --color-sidebar-accent-foreground: var(--sidebar-accent-foreground);
    --color-sidebar-border: var(--sidebar-border);
    --color-sidebar-ring: var(--sidebar-ring);

    --font-sans: var(--font-sans);
    --font-mono: var(--font-mono);
    --font-serif: var(--font-serif);

    --radius-sm: calc(var(--radius) - 4px);
    --radius-md: calc(var(--radius) - 2px);
    --radius-lg: var(--radius);
    --radius-xl: calc(var(--radius) + 4px);

    --shadow-2xs: var(--shadow-2xs);
    --shadow-xs: var(--shadow-xs);
    --shadow-sm: var(--shadow-sm);
    --shadow: var(--shadow);
    --shadow-md: var(--shadow-md);
    --shadow-lg: var(--shadow-lg);
    --shadow-xl: var(--shadow-xl);
    --shadow-2xl: var(--shadow-2xl);

    --transition-delay-10000: 10000ms;

    @keyframes logo-spin {
        0% {
            transform: rotate(0deg);
        }
        30% {
            transform: rotate(360deg);
        }
        100% {
            transform: rotate(360deg);
        }
    }
    @keyframes roll-reveal {
        from {
            opacity: 0;
            transform: rotate(12deg) scale(0);
        }
        to {
            opacity: 1;
            transform: rotate(0deg) scale(1);
        }
    }
    @keyframes slide-left {
        from {
            opacity: 0;
            transform: translateX(20px);
        }
        to {
            opacity: 1;
            transform: translateX(0px);
        }
    }
    @keyframes slide-top {
        from {
            opacity: 0;
            transform: translateY(20px);
        }
        to {
            opacity: 1;
            transform: translateY(0px);
        }
    }
}

/*
  The default border color has changed to `currentcolor` in Tailwind CSS v4,
  so we've added these compatibility styles to make sure everything still
  looks the same as it did with Tailwind CSS v3.

  If we ever want to remove these styles, we need to add an explicit border
  color utility to any element that depends on these defaults.
*/
@layer base {
    *,
    ::after,
    ::before,
    ::backdrop,
    ::file-selector-button {
        border-color: var(--color-gray-200, currentcolor);
    }
}

@layer base {
    :root {
        --background: oklch(1 0 0);
        --foreground: oklch(0.32 0 0);
        --card: oklch(1 0 0);
        --card-foreground: oklch(0.32 0 0);
        --popover: oklch(1 0 0);
        --popover-foreground: oklch(0.32 0 0);
        --primary: oklch(0.25 0.14 245);
        --primary-foreground: oklch(1 0 0);
        --secondary: oklch(0.97 0 240);
        --secondary-foreground: oklch(0.45 0.03 240);
        --muted: oklch(0.98 0 240);
        --muted-foreground: oklch(0.55 0.02 240);
        --accent: oklch(0.9 0.03 245);
        --accent-foreground: oklch(0.32 0 0);
        --destructive: oklch(0.54 0.21 25);
        --destructive-foreground: oklch(1 0 0);
        --border: oklch(0.91 0.01 240);
        --input: oklch(0.91 0.01 240);
        --ring: oklch(0.25 0.14 245);
        --chart-1: oklch(0.25 0.14 245);
        --chart-2: oklch(0.38 0.18 245);
        --chart-3: oklch(0.5 0.22 245);
        --chart-4: oklch(0.42 0.1 245);
        --chart-5: oklch(0.55 0.14 245);
        --sidebar: oklch(0.98 0 240);
        --sidebar-foreground: oklch(0.32 0 0);
        --sidebar-primary: oklch(0.25 0.14 245);
        --sidebar-primary-foreground: oklch(1 0 0);
        --sidebar-accent: oklch(0.9 0.03 245);
        --sidebar-accent-foreground: oklch(0.32 0 0);
        --sidebar-border: oklch(0.93 0.01 240);
        --sidebar-ring: oklch(0.25 0.14 245);
        /* Link TEXT. --primary is a fill (paired with white --primary-foreground) and cannot double as
           text: on dark it measures 3.12:1 on --card, and no lightness clears AA in both roles at once. */
        --link: oklch(0.25 0.14 245);
        /* Editor highlight TEXT, tuned for readable contrast on the editor surface (unlike --primary, a fill
           color that fails WCAG AA as text on dark). Four distinct hues so adjacent tokens don't blur:
           link = theme blue 245; variable = green 155 (matches the panel's "used" badge); tag = violet 300;
           inline code = red 25 on a visible chip.
           --editor-code-bg is the opaque inline-code + code-block chip. Don't fold these back into --primary. */
        --editor-accent: oklch(0.25 0.12 245);
        --editor-variable: oklch(0.4 0.18 155);
        --editor-tag: oklch(0.25 0.12 300);
        --editor-code: oklch(0.5 0.16 25);
        --editor-code-bg: oklch(0.94 0.006 245);
        /* Stock atom-one-light is NOT usable as-is: on this surface it fails AA on 6 of its 8 token colours.
           These hold its hues and chroma but lower lightness until each clears it. */
        --editor-syntax-fg: oklch(0.35 0.014 274.5);
        --editor-syntax-comment: oklch(0.52 0.009 278.6);
        --editor-syntax-keyword: oklch(0.524 0.211 328.8);
        --editor-syntax-entity: oklch(0.539 0.179 28.3);
        --editor-syntax-literal: oklch(0.511 0.126 236.7);
        --editor-syntax-string: oklch(0.503 0.142 143.5);
        --editor-syntax-attr: oklch(0.524 0.116 76.9);
        --editor-syntax-symbol: oklch(0.527 0.193 263.2);
        --editor-syntax-class: oklch(0.523 0.138 76.2);
        --font-sans: Inter, 'Inter Fallback', sans-serif;
        --font-serif: Inter, 'Inter Fallback', serif;
        --font-mono: 'Roboto Mono', monospace;
        --radius: 0.375rem;
        --shadow-x: 0;
        --shadow-y: 1px;
        --shadow-blur: 3px;
        --shadow-spread: 0px;
        --shadow-opacity: 0.1;
        --shadow-color: oklch(0 0 0);
        --shadow-2xs: 0 1px 3px 0px hsl(0 0% 0% / 0.05);
        --shadow-xs: 0 1px 3px 0px hsl(0 0% 0% / 0.05);
        --shadow-sm: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 1px 2px -1px hsl(0 0% 0% / 0.1);
        --shadow: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 1px 2px -1px hsl(0 0% 0% / 0.1);
        --shadow-md: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 2px 4px -1px hsl(0 0% 0% / 0.1);
        --shadow-lg: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 4px 6px -1px hsl(0 0% 0% / 0.1);
        --shadow-xl: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 8px 10px -1px hsl(0 0% 0% / 0.1);
        --shadow-2xl: 0 1px 3px 0px hsl(0 0% 0% / 0.25);
        --tracking-normal: 0em;
        --spacing: 0.25rem;
    }

    .dark {
        --background: oklch(0.15 0.02 245);
        --foreground: oklch(0.92 0 0);
        --card: oklch(0.2 0.03 245);
        --card-foreground: oklch(0.92 0 0);
        --popover: oklch(0.2 0.03 245);
        --popover-foreground: oklch(0.92 0 0);
        --primary: oklch(0.5 0.16 245);
        --primary-foreground: oklch(1 0 0);
        --secondary: oklch(0.25 0.04 245);
        --secondary-foreground: oklch(0.92 0 0);
        --muted: oklch(0.22 0.03 245);
        --muted-foreground: oklch(0.72 0 0);
        --accent: oklch(0.24 0.09 245);
        --accent-foreground: oklch(0.92 0.02 245);
        --destructive: oklch(0.64 0.21 25);
        --destructive-foreground: oklch(1 0 0);
        --border: oklch(0.3 0.04 245);
        --input: oklch(0.3 0.04 245);
        --ring: oklch(0.5 0.16 245);
        --chart-1: oklch(0.5 0.16 245);
        --chart-2: oklch(0.6 0.2 245);
        --chart-3: oklch(0.7 0.22 245);
        --chart-4: oklch(0.58 0.1 245);
        --chart-5: oklch(0.74 0.14 245);
        --sidebar: oklch(0.15 0.02 245);
        --sidebar-foreground: oklch(0.92 0 0);
        --sidebar-primary: oklch(0.5 0.16 245);
        --sidebar-primary-foreground: oklch(1 0 0);
        --sidebar-accent: oklch(0.24 0.09 245);
        --sidebar-accent-foreground: oklch(0.92 0.02 245);
        --sidebar-border: oklch(0.3 0.04 245);
        --sidebar-ring: oklch(0.5 0.16 245);
        --link: oklch(0.68 0.13 245);
        --editor-accent: oklch(0.68 0.13 245);
        --editor-variable: oklch(0.72 0.12 155);
        --editor-tag: oklch(0.68 0.13 300);
        --editor-code: oklch(0.7 0.15 25);
        --editor-code-bg: oklch(0.27 0.03 245);
        /* atom-one-dark's hues, which already clear AA here — except comment and entity, tuned because
           stock measures 2.49 and 4.70. */
        --editor-syntax-fg: oklch(0.762 0.02 263);
        --editor-syntax-comment: oklch(0.688 0.019 261.3);
        --editor-syntax-keyword: oklch(0.694 0.164 318.2);
        --editor-syntax-entity: oklch(0.694 0.131 16.3);
        --editor-syntax-literal: oklch(0.723 0.092 206.3);
        --editor-syntax-string: oklch(0.768 0.11 133);
        --editor-syntax-attr: oklch(0.727 0.095 63.8);
        --editor-syntax-symbol: oklch(0.728 0.121 245.6);
        --editor-syntax-class: oklch(0.826 0.097 81.6);
        --font-sans: Inter, 'Inter Fallback', sans-serif;
        --font-serif: Inter, 'Inter Fallback', serif;
        --font-mono: 'Roboto Mono', monospace;
        --radius: 0.5rem;
        --shadow-x: 0;
        --shadow-y: 1px;
        --shadow-blur: 3px;
        --shadow-spread: 0px;
        --shadow-opacity: 0.1;
        --shadow-color: oklch(0 0 0);
        --shadow-2xs: 0 1px 3px 0px hsl(0 0% 0% / 0.05);
        --shadow-xs: 0 1px 3px 0px hsl(0 0% 0% / 0.05);
        --shadow-sm: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 1px 2px -1px hsl(0 0% 0% / 0.1);
        --shadow: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 1px 2px -1px hsl(0 0% 0% / 0.1);
        --shadow-md: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 2px 4px -1px hsl(0 0% 0% / 0.1);
        --shadow-lg: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 4px 6px -1px hsl(0 0% 0% / 0.1);
        --shadow-xl: 0 1px 3px 0px hsl(0 0% 0% / 0.1), 0 8px 10px -1px hsl(0 0% 0% / 0.1);
        --shadow-2xl: 0 1px 3px 0px hsl(0 0% 0% / 0.25);
    }

    ::-webkit-scrollbar {
        width: 8px;
        height: 8px;
    }

    ::-webkit-scrollbar-track {
        background: transparent;
        border-radius: 4px;
    }

    ::-webkit-scrollbar-thumb {
        background: oklch(from var(--muted-foreground) l c h / 0.3);
        border-radius: 4px;
    }

    ::-webkit-scrollbar-thumb:hover {
        background: oklch(from var(--muted-foreground) l c h / 0.5);
    }

    * {
        scrollbar-color: oklch(from var(--muted-foreground) l c h / 0.3) transparent;
    }
}

@layer base {
    * {
        @apply border-border;
    }
    body {
        @apply bg-background text-foreground;
    }

    button:not(:disabled),
    [role='button']:not(:disabled) {
        cursor: pointer;
    }
}

/* Tailwind Typography wraps inline <code> in literal `backticks` via ::before/::after — that is markdown SOURCE,
   not how rendered inline code should look. Drop them so it reads as styled code, matching tiptap's demos. */
.prose code::before,
.prose code::after {
    content: none;
}

/* Inline code in the read-only viewer mirrors the editor (red text on a visible chip) so a document reads
   the same whether it is being edited or viewed. Code blocks keep hljs syntax highlighting (see below). */
.prose code:not(pre code) {
    color: var(--editor-code);
    background-color: var(--editor-code-bg);
    padding: 0.125rem 0.25rem;
    border-radius: calc(var(--radius) - 4px);
    font-weight: inherit;
}

.prose-xs {
    font-size: 0.875rem;
    line-height: 1.25rem;
}

.prose-xs hr {
    margin-top: 1.5em;
    margin-bottom: 1.5em;
}

.prose-xs h1,
.prose-xs h2,
.prose-xs h3,
.prose-xs h4,
.prose-xs h5,
.prose-xs h6 {
    margin-top: 1.5em;
    margin-bottom: 0.5em;
}

.prose-xs p {
    margin-top: 1.5em;
    margin-bottom: 1.5em;
}

.prose-xs p:first-child {
    margin-top: 0;
}

.prose-xs p:last-child {
    margin-bottom: 0;
}

.prose-xs pre {
    margin-top: 1.5em;
    font-size: 1em;
    line-height: 1.5;
}

.prose-xs ul,
.prose-xs ol {
    margin-top: 1.5em;
    margin-bottom: 1.5em;
}

.prose-xs ul ul,
.prose-xs ul ol,
.prose-xs ol ol,
.prose-xs ol ul {
    margin-top: 0.5em;
    margin-bottom: 0.5em;
}

.prose-xs li {
    margin-top: 0.5em;
    margin-bottom: 0.5em;
}

.prose-xs ul > li > p,
.prose-xs ol > li > p,
.prose-xs ul > li > pre,
.prose-xs ol > li > pre {
    margin-top: 0.5em;
    margin-bottom: 0.5em;
}

.prose-xs ul > li > p:first-child,
.prose-xs ol > li > p:first-child {
    margin-top: 0;
}

.prose-xs ul > li > p:last-child,
.prose-xs ol > li > p:last-child {
    margin-bottom: 0;
}

.prose-xs h1 + ul,
.prose-xs h1 + ol,
.prose-xs h2 + ul,
.prose-xs h2 + ol,
.prose-xs h3 + ul,
.prose-xs h3 + ol,
.prose-xs h4 + ul,
.prose-xs h4 + ol,
.prose-xs h5 + ul,
.prose-xs h5 + ol,
.prose-xs h6 + ul,
.prose-xs h6 ol {
    margin-top: 0;
}

.prose-xs :first-child {
    margin-top: 0;
}

.prose-xs :last-child {
    margin-bottom: 0;
}

.prose-fixed h1,
.prose-fixed h2,
.prose-fixed h3,
.prose-fixed h4,
.prose-fixed h5,
.prose-fixed h6 {
    font-size: 1em;
    line-height: 1.5;
}

.prose pre code.hljs {
    color: inherit;
    background: transparent;
    padding: 0;
    overflow: visible;
}

/* Without these the viewer falls back to Tailwind Typography's own pre colours, which are dark in BOTH
   themes (gray-800 light / `rgb(0 0 0 / 50%)` dark) and are plugin internals, not project tokens. */
.prose {
    --tw-prose-pre-bg: var(--editor-code-bg);
    --tw-prose-pre-code: var(--editor-syntax-fg);
    --tw-prose-invert-pre-bg: var(--editor-code-bg);
    --tw-prose-invert-pre-code: var(--editor-syntax-fg);
}

/* Sonner */
[data-sonner-toast][data-styled='true'] {
    gap: 8px !important;
}

[data-sonner-toast][data-styled='true'] [data-icon] {
    align-self: flex-start;
    margin: 2px 0;
}

[data-sonner-toast][data-styled='true'] [data-title] {
    font-size: 14px !important;
    font-weight: 500 !important;
    line-height: 20px !important;
}

[data-sonner-toaster][data-sonner-theme='dark'] [data-description],
[data-sonner-toaster][data-sonner-theme='light'] [data-description] {
    font-size: 12px !important;
    font-weight: 400 !important;
    line-height: 16px !important;
    color: var(--muted-foreground) !important;
}

.recharts-wrapper,
.recharts-wrapper * {
    outline: none !important;
}

/* Tiptap editor */
.tiptap-content .ProseMirror {
    outline: none;
    min-height: 100%;
}

.tiptap-content .ProseMirror p.is-editor-empty:first-child::before {
    color: var(--muted-foreground);
    opacity: 0.6;
    content: attr(data-placeholder);
    float: left;
    height: 0;
    pointer-events: none;
}

.tiptap-content .ProseMirror > :first-child {
    margin-top: 0;
}

.tiptap-content .ProseMirror > :last-child {
    margin-bottom: 0;
}

.tiptap-content .ProseMirror p.is-empty::before {
    content: '';
}

.tiptap-content .ProseMirror code:not(pre code) {
    color: var(--editor-code);
    background-color: var(--editor-code-bg);
    padding: 0.125rem 0.25rem;
    border-radius: calc(var(--radius) - 4px);
    font-size: 0.875em;
}

.tiptap-content .ProseMirror pre {
    position: relative;
    padding: 0.75rem 1rem;
    border-radius: calc(var(--radius) - 2px);
    overflow-x: auto;
}

.tiptap-content .ProseMirror pre,
.prose pre {
    background: var(--editor-code-bg);
    color: var(--editor-syntax-fg);
}

.dark .tiptap-content .ProseMirror pre {
    --editor-variable: oklch(0.76 0.12 155);
    --editor-tag: oklch(0.76 0.13 300);
}

/* data-language is a DOM-only attribute (stamped by renderHTML); it never enters the serialized markdown. */
.tiptap-content .ProseMirror pre[data-language]::before {
    content: attr(data-language);
    display: block;
    margin: -0.75rem -1rem 0.75rem;
    padding: 0.25rem 1rem;
    border-bottom: 1px solid color-mix(in oklab, var(--editor-syntax-fg) 14%, transparent);
    border-radius: calc(var(--radius) - 2px) calc(var(--radius) - 2px) 0 0;
    background-color: color-mix(in oklab, var(--editor-syntax-fg) 7%, transparent);
    color: color-mix(in oklab, var(--editor-syntax-fg) 85%, transparent);
    font-family: var(--font-mono);
    font-size: 0.7rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.tiptap-content .ProseMirror pre code {
    background: transparent;
    padding: 0;
    font-size: 0.875em;
}

/* Do not go back to importing a highlight.js stylesheet: a side-effect CSS import cannot be scoped to a
   theme, so the fence could not follow light/dark at all. Groups mirror atom-one's. */
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-comment,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-quote {
    color: var(--editor-syntax-comment);
    font-style: italic;
}

:is(.tiptap-content .ProseMirror, .prose) pre .hljs-doctag,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-keyword,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-formula {
    color: var(--editor-syntax-keyword);
}

:is(.tiptap-content .ProseMirror, .prose) pre .hljs-section,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-name,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-selector-tag,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-deletion,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-subst {
    color: var(--editor-syntax-entity);
}

:is(.tiptap-content .ProseMirror, .prose) pre .hljs-literal {
    color: var(--editor-syntax-literal);
}

:is(.tiptap-content .ProseMirror, .prose) pre .hljs-string,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-regexp,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-addition,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-attribute,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-meta .hljs-string {
    color: var(--editor-syntax-string);
}

:is(.tiptap-content .ProseMirror, .prose) pre .hljs-attr,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-variable,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-template-variable,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-type,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-selector-class,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-selector-attr,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-selector-pseudo,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-number {
    color: var(--editor-syntax-attr);
}

:is(.tiptap-content .ProseMirror, .prose) pre .hljs-symbol,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-bullet,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-link,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-meta,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-selector-id,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-title {
    color: var(--editor-syntax-symbol);
}

:is(.tiptap-content .ProseMirror, .prose) pre .hljs-built_in,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-title.class_,
:is(.tiptap-content .ProseMirror, .prose) pre .hljs-class .hljs-title {
    color: var(--editor-syntax-class);
}

:is(.tiptap-content .ProseMirror, .prose) pre .hljs-emphasis {
    font-style: italic;
}

:is(.tiptap-content .ProseMirror, .prose) pre .hljs-strong {
    font-weight: 700;
}

.tiptap-content .ProseMirror blockquote {
    border-left: 3px solid var(--border);
    padding-left: 1rem;
    color: var(--muted-foreground);
}

.tiptap-content .ProseMirror a {
    color: var(--editor-accent);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.tiptap-content .ProseMirror hr {
    border: 0;
    border-top: 1px solid var(--border);
    margin: 1.5rem 0;
}

.tiptap-content .ProseMirror table {
    border-collapse: collapse;
    table-layout: fixed;
    width: 100%;
    margin: 0.75rem 0;
    overflow: hidden;
}

.tiptap-content .ProseMirror th,
.tiptap-content .ProseMirror td {
    position: relative;
    min-width: 4rem;
    border: 1px solid var(--border);
    padding: 0.375rem 0.5rem;
    vertical-align: top;
}

.tiptap-content .ProseMirror th {
    background-color: var(--muted);
    font-weight: 600;
    text-align: left;
}

.tiptap-content .ProseMirror th > *,
.tiptap-content .ProseMirror td > * {
    margin: 0;
}

/* Selected-cell overlay + column resize handle (prosemirror-tables) */
.tiptap-content .ProseMirror .selectedCell::after {
    content: '';
    position: absolute;
    inset: 0;
    background: color-mix(in oklab, var(--primary) 15%, transparent);
    pointer-events: none;
}

.tiptap-content .ProseMirror .column-resize-handle {
    position: absolute;
    top: 0;
    bottom: -2px;
    right: -2px;
    width: 4px;
    background-color: var(--primary);
    pointer-events: none;
}

.tiptap-content .ProseMirror.resize-cursor {
    cursor: col-resize;
}

.tiptap-content .ProseMirror ul[data-type='taskList'] {
    list-style: none;
    padding-left: 0;
}

.tiptap-content .ProseMirror ul[data-type='taskList'] li {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
}

.tiptap-content .ProseMirror ul[data-type='taskList'] li > label {
    margin-top: 0.2rem;
    user-select: none;
}

.tiptap-content .ProseMirror ul[data-type='taskList'] li > div {
    flex: 1 1 auto;
    min-width: 0;
}

.tiptap-content .ProseMirror ul[data-type='taskList'] li > div > p {
    margin: 0;
}

.tiptap-content .ProseMirror img {
    max-width: 100%;
    height: auto;
    border-radius: calc(var(--radius) - 4px);
}

/* Every selectable node, not just images: a NodeSelection on an `hr` had no visual at all, and since
   `.ProseMirror-hideselection` blanks the native highlight at the same time, the next keystroke replaced a
   node the user could not see was selected. prosemirror-view ships an outline rule for this, but its
   stylesheet is imported nowhere and tiptap's injected CSS carries no equivalent. */
.tiptap-content .ProseMirror .ProseMirror-selectednode {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

.tiptap-content .ProseMirror img.ProseMirror-selectednode {
    outline-offset: 0;
}

/* tiptap injects `border-top: 1px solid black` for the gap cursor, so on the dark theme the caret you get
   between two block nodes (pressing left/up at the start of a leading table or fence) is a black line on a
   near-black background — a caret position with no visible caret. */
.tiptap-content .ProseMirror-gapcursor::after {
    border-top-color: var(--foreground);
}

/* `{{ ... }}` Go-template actions, highlighted via view-only decorations (document bytes untouched). */
.tiptap-content .ProseMirror .template-variable {
    color: var(--editor-variable);
    background-color: color-mix(in oklab, var(--editor-variable) 9%, transparent);
    border-radius: calc(var(--radius) - 4px);
    padding: 0 1px;
}

/* `<xml-tags>`, highlighted view-only. */
.tiptap-content .ProseMirror .template-tag {
    color: var(--editor-tag);
    background-color: color-mix(in oklab, var(--editor-tag) 9%, transparent);
    border-radius: calc(var(--radius) - 4px);
    padding: 0 1px;
}