/* Carbon Labs: the CTA buttons in the monday AI "Liquid Glass" material (from the CarbonWeb Design System's
   monday-ai-v4 button). Every .btn keeps its own fill and colours from brand.css; on top it gets the same glass:
   the ten-layer rim, the lens refraction (#auroraLens in the page), a specular that follows the pointer and a
   halo inside the glass (glass.js writes --au-glow-x / --au-glow-y / --au-glow-on), the 2px lift on hover and the
   press. Text links are not touched. */
:root {
  --au-glass-light: 1; --au-glass-dark: 1;
  --au-glass-stack:
    inset 0 0 0 1px          color-mix(in srgb, #fff calc(var(--au-glass-light) * 12%), transparent),
    inset 1.8px 3px 0 -2px   color-mix(in srgb, #fff calc(var(--au-glass-light) * 78%), transparent),
    inset -2px -2px 0 -2px   color-mix(in srgb, #fff calc(var(--au-glass-light) * 58%), transparent),
    inset -3px -8px 1px -6px color-mix(in srgb, #fff calc(var(--au-glass-light) * 42%), transparent),
    inset -0.3px -1px 4px 0  color-mix(in srgb, #000 calc(var(--au-glass-dark) * 14%), transparent),
    inset -1.5px 2.5px 0 -2px color-mix(in srgb, #000 calc(var(--au-glass-dark) * 18%), transparent),
    inset 0 3px 4px -2px     color-mix(in srgb, #000 calc(var(--au-glass-dark) * 18%), transparent),
    inset 2px -6.5px 1px -4px color-mix(in srgb, #000 calc(var(--au-glass-dark) * 10%), transparent),
    0 1px 5px 0              color-mix(in srgb, #000 calc(var(--au-glass-dark) * 22%), transparent),
    0 10px 26px -8px         color-mix(in srgb, #000 calc(var(--au-glass-dark) * 26%), transparent);
  --au-glow-teal: 0 10px 26px -6px color-mix(in srgb, #00B0C2 45%, transparent);
}
html[data-theme="light"] { --au-glass-dark: .34; }   /* the source's .au-day: no grey, muddy inner shadows on white */

html .btn {
  --au-glow-x: 50%; --au-glow-y: 50%; --au-glow-on: 0; --au-glow-size: 120px;
  position: relative; isolation: isolate; overflow: hidden;
  box-shadow: var(--au-glass-stack), var(--au-glow-teal);
  backdrop-filter: blur(8px) saturate(150%);
  -webkit-backdrop-filter: blur(8px) saturate(150%);
  transition: transform 200ms cubic-bezier(.16,1,.3,1), box-shadow 420ms cubic-bezier(1,0,.4,1), background 200ms ease;
}
html[data-theme="light"] .btn, html:not([data-theme="light"]) .btn,
html[data-theme="light"] .nav .btn--ink, html:not([data-theme="light"]) .nav .btn--ink,
html[data-theme="light"] .btn--teal, html:not([data-theme="light"]) .btn--teal {
  box-shadow: var(--au-glass-stack), var(--au-glow-teal);
  backdrop-filter: blur(8px) saturate(150%); -webkit-backdrop-filter: blur(8px) saturate(150%);
}
/* the halo, inside the glass, following the pointer: white into Carbon's light blue */
html .btn::before {
  content: ""; position: absolute; inset: -40%; z-index: -1; border-radius: inherit; pointer-events: none;
  background: radial-gradient(38% 60% at var(--au-glow-x) var(--au-glow-y), rgba(242,254,255,.62), rgba(201,250,255,.28) 45%, transparent 72%);   /* almost white with a hint of teal, like the source's light (the teal fill underneath is kept by the hover rule below) */
  opacity: var(--au-glow-on); transition: opacity 420ms ease;
}
/* the specular on the glass itself */
html .btn::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: radial-gradient(var(--au-glow-size) circle at var(--au-glow-x) var(--au-glow-y), rgba(246,254,255,.34), transparent 60%);
  opacity: var(--au-glow-on); transition: opacity 420ms ease;
}
/* the lens refraction (an SVG filter run over the backdrop) is the dearest part of the glass: the buttons sit over the
   moving hero, so at rest it was recomputed every frame. It now applies only while a button is hovered or focused. */
html .btn:hover, html .btn:focus-visible { backdrop-filter: blur(8px) url(#auroraLens) saturate(150%); }
html .btn:hover { transform: translateY(-2px); }
html .btn:active { transform: scale(.975); opacity: 1; }
html .btn svg { transition: transform 200ms cubic-bezier(.16,1,.3,1); }
html .btn:hover svg { transform: translateX(3px); }
html .btn:focus-visible { outline: 2px solid #00B0C2; outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) {
  html .btn { transition: none; } html .btn::after { display: none; }
  html .btn:hover, html .btn:hover svg { transform: none; }
}

/* the secondary CTA (.btn--glass, e.g. "Read Labs Stages V2") in the source's ghost flavour: no fill, only the glass
   edge, its ink from the surface. On white it drops to a 4% tint with a 1px grey keyline, deepening on hover. */
html:not([data-theme="light"]) .btn.btn--glass { color: #E3E1E1; background: rgba(255,255,255,.06); border: 0; box-shadow: var(--au-glass-stack); }
html:not([data-theme="light"]) .btn.btn--glass:hover { background: rgba(255,255,255,.06); }
html[data-theme="light"] .btn.btn--glass { color: #0A0A0A; background: rgba(0,0,0,.04); border: 0; box-shadow: inset 0 0 0 1px #D4D6D9; }
html[data-theme="light"] .btn.btn--glass:hover { background: rgba(10,10,10,.08); }

/* hover keeps the fill teal: the brand's teal corner stays (no greying from the backdrop or the shadow), only brighter */
html:not([data-theme="light"]) .btn:not(.btn--glass):not(.btn--teal):not(.nav .btn):hover { background: radial-gradient(70% 140% at 8% 12%, rgba(0,176,194,.8) 0%, rgba(0,176,194,.3) 38%, rgba(0,176,194,0) 72%), rgba(189,240,244,.16); }
html[data-theme="light"] .btn:not(.btn--glass):not(.btn--teal):not(.nav .btn):hover { background: radial-gradient(70% 140% at 8% 12%, rgba(0,176,194,.7) 0%, rgba(0,176,194,.26) 38%, rgba(0,176,194,0) 72%), rgba(222,251,255,.78); }

/* the secondary (ghost) CTAs light up in pure white, no teal */
html .btn.btn--glass::before { background: radial-gradient(38% 60% at var(--au-glow-x) var(--au-glow-y), rgba(255,255,255,.62), rgba(255,255,255,.22) 45%, transparent 72%); }
html .btn.btn--glass::after { background: radial-gradient(var(--au-glow-size) circle at var(--au-glow-x) var(--au-glow-y), rgba(255,255,255,.34), transparent 60%); }

/* light mode keeps the brand's glass pill for the main CTAs (brand.css), Jack's audit pick (2026-10-22, confirmed
   2026-10-23). Dark mode's main CTAs are the solid teal pill, set in brand.css. */

/* the main CTAs' label in light mode: teal (the brand's teal-dark, the teal that reads on the pale glass), rolled
   out from the "Book a demo" test (Amy, 2026-10-23). The solid teal pills (nav Experiments, .btn--teal) keep their
   white label, ghost buttons keep their own ink, and dark mode is unchanged. */
html[data-theme="light"] .btn:not(.btn--glass):not(.btn--teal):not(.nav .btn) { color: #00828F; }
