/* Cookie banner and form error of the marketing site (see site.js). Colours and type follow tokens.css. */

/* The pages toggle blocks with the hidden attribute (the demo form after sending, its
   thank-you note); their own display rules (.dform is a flex box) would otherwise win. */
[hidden] { display: none !important; }
.ss-cookies {
  position: fixed;
  z-index: 70;
  left: max(16px, env(safe-area-inset-left, 0px));
  bottom: max(16px, env(safe-area-inset-bottom, 0px));
  width: min(392px, calc(100vw - 32px));
  padding: 18px 18px 16px;
  border-radius: 14px;
  background: #FDFCFB;
  color: #17130E;
  box-shadow: inset 0 0 0 1px rgba(23, 19, 14, .08), 0 28px 60px -24px rgba(23, 19, 14, .35);
  font: 400 14px/1.5 'Hanken Grotesk', 'Onest', system-ui, sans-serif;
  animation: ss-rise .45s cubic-bezier(.2, .85, .25, 1) both;
}
.ss-cookies p { margin: 0 0 14px; text-wrap: pretty; }
.ss-cookies a { color: inherit; text-decoration: underline; text-decoration-color: rgba(23, 19, 14, .35); text-underline-offset: 3px; }
.ss-cookies a:hover { color: #E5875C; text-decoration-color: currentColor; }
.ss-cookies-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.ss-btn {
  min-height: 44px;
  padding: 0 16px;
  border-radius: 10px;
  border: 1px solid rgba(23, 19, 14, .16);
  background: transparent;
  color: #17130E;
  font: 500 14px/1 'Hanken Grotesk', 'Onest', system-ui, sans-serif;
  cursor: pointer;
  transition: background .2s ease, border-color .2s ease;
}
.ss-btn:hover { background: rgba(23, 19, 14, .05); }
.ss-btn--primary { background: #17130E; border-color: #17130E; color: #FDFCFB; }
.ss-btn--primary:hover { background: #2A241C; }
.ss-btn:focus-visible, .ss-cookies a:focus-visible { outline: 2px solid #17130E; outline-offset: 2px; }
.ss-form-error { margin: 0 0 12px; color: #B42318; font: 500 14px/1.45 'Hanken Grotesk', 'Onest', system-ui, sans-serif; }
/* Language switcher: a dropdown in the desktop header, a row in the mobile panel. */
.ss-lang { position: relative; flex: none; }
.ss-lang > summary {
  list-style: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 40px;
  padding: 0 10px;
  border-radius: 8px;
  color: #17130E;
  font: 500 14px/1 'Hanken Grotesk', 'Onest', system-ui, sans-serif;
  letter-spacing: .02em;
  cursor: pointer;
  transition: background .2s ease;
}
.ss-lang > summary::-webkit-details-marker { display: none; }
.ss-lang > summary:hover, .ss-lang[open] > summary { background: rgba(23, 19, 14, .05); }
.ss-lang > summary svg:last-child { transition: transform .2s ease; opacity: .6; }
.ss-lang[open] > summary svg:last-child { transform: rotate(180deg); }
.ss-lang > summary:focus-visible { outline: 2px solid #17130E; outline-offset: 2px; }
.ss-lang-menu {
  position: absolute;
  z-index: 80;
  right: 0;
  top: calc(100% + 8px);
  min-width: 184px;
  padding: 6px;
  display: grid;
  border-radius: 12px;
  background: #FDFCFB;
  box-shadow: inset 0 0 0 1px rgba(23, 19, 14, .08), 0 28px 60px -24px rgba(23, 19, 14, .3);
  animation: ss-rise .2s cubic-bezier(.2, .85, .25, 1) both;
}
.ss-lang-menu a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 40px;
  padding: 0 12px;
  border-radius: 8px;
  color: #17130E;
  font: 500 14px/1 'Hanken Grotesk', 'Onest', system-ui, sans-serif;
  text-decoration: none;
}
.ss-lang-menu a:hover { background: #EFEBE2; color: #17130E; }
.ss-lang-menu a[aria-current="true"] { font-weight: 600; }
.ss-lang-menu a[aria-current="true"]::after { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #E5875C; }
@media (max-width: 1000px) { .ss-lang { display: none; } }

.m-nav .ss-lang-row { display: flex; gap: 6px; }
.m-panel .ss-lang-row { padding: 12px 0; border-bottom: 1px solid rgba(23, 19, 14, .08); }
.m-nav-panel .ss-lang-row { padding: 6px 14px 8px; }
.m-nav .ss-lang-row a {
  flex: 1 1 0;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 40px;
  min-height: 40px;
  padding: 0;
  border: 1px solid rgba(23, 19, 14, .14);
  border-radius: 8px;
  background: transparent;
  color: #17130E;
  font: 600 13px/1 'Hanken Grotesk', 'Onest', system-ui, sans-serif;
  letter-spacing: .06em;
  text-decoration: none;
}
.m-nav .ss-lang-row a[aria-current="true"] { background: #17130E; border-color: #17130E; color: #FDFCFB; }

/* Blog list: topic chips are links (server-side filter), styled as the design's chip buttons. */
.chips a.sd-chip { flex: none; height: 36px; padding: 0 14px; font: 500 14px/1 var(--f-text); letter-spacing: 0; text-transform: none; text-decoration: none; transition: background .2s, color .2s, box-shadow .2s; }
.chips a.sd-chip:hover { box-shadow: inset 0 0 0 1px var(--ink); color: var(--ink); }
.chips a.sd-chip[aria-current="page"] { background: var(--ink); color: var(--bg); box-shadow: none; }

@keyframes ss-rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .ss-cookies { animation: none; } }
@media (max-width: 480px) { .ss-cookies { bottom: max(12px, env(safe-area-inset-bottom, 0px)); } .ss-btn { flex: 1 1 auto; } }
