:is(.kore-image-figure, .image, figure.image, .kore-image) {
  margin: 0;
  transition: var(--motion);
  display: block;
  position: relative;
  overflow: hidden;
  width: 100%;
  max-width: var(--local-width, 100%);
  isolation: isolate;
  transform: translateZ(0); 
  border-radius: var(--local-radius, 0);
}

/* Logos & Brand Marks: Absolute immunity against border radius clipping */
:is(.logo-img, .footer-logo-img, .site-logo, .brand-logo, [class*="logo-img"]) {
  border-radius: 0 !important;
}
:is(.logo-img, .footer-logo-img, .site-logo, .brand-logo, [class*="logo-img"]) :is(img, .kore-image, .kore-image-wrap, .kore-picture) {
  border-radius: 0 !important;
}

:is(.kore-image-figure, .image, figure.image, .kore-image):is(.ratio-auto, .aspect-auto, [data-ratio="auto"]) {
  min-height: 0.0625rem;
}
:is(.kore-image-figure, .image, figure.image, .kore-image):is(.ratio-auto, .aspect-auto, [data-ratio="auto"]):not(.img-cover):not(.h-full):not([class*="h-full"]):not(.avatar):not([class*="avatar-"]) .kore-image-wrap {
  position: relative;
  height: auto;
}
:is(.kore-image-figure, .image, figure.image, .kore-image):is(.ratio-auto, .aspect-auto, [data-ratio="auto"]):not(.img-cover):not(.h-full):not([class*="h-full"]):not(.avatar):not([class*="avatar-"]) .kore-picture,
:is(.kore-image-figure, .image, figure.image, .kore-image):is(.ratio-auto, .aspect-auto, [data-ratio="auto"]):not(.img-cover):not(.h-full):not([class*="h-full"]):not(.avatar):not([class*="avatar-"]) .kore-picture img,
:is(.kore-image-figure, .image, figure.image, .kore-image):is(.ratio-auto, .aspect-auto, [data-ratio="auto"]):not(.img-cover):not(.h-full):not([class*="h-full"]):not(.avatar):not([class*="avatar-"]) .kore-image {
  height: auto;
}

:is(.kore-image-figure, .image, figure.image, .kore-image):is(.h-full, [class*="h-full"]) {
  height: 100% !important;
}

:is(.kore-image-figure, .image, figure.image, .kore-image):is(.h-full, [class*="h-full"]) .kore-image-wrap {
  position: relative;
  width: 100% !important;
  height: 100% !important;
}

:is(.kore-image-figure, .image, figure.image, .kore-image):is(.h-full, [class*="h-full"]) :is(.kore-picture, picture) {
  display: block;
  width: 100% !important;
  height: 100% !important;
}

:is(.kore-image-figure, .image, figure.image, .kore-image):is(.h-full, [class*="h-full"]) :is(.kore-image, img, .kore-picture img) {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover;
}

:is(.kore-image-figure, .image, figure.image, .kore-image).img-cover {
  position: absolute !important;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  z-index: 0 !important;
  pointer-events: none !important;
}

:is(.kore-image-figure, .image, figure.image, .kore-image).img-cover .kore-image-wrap {
  position: absolute !important;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
}

:is(.kore-image-figure, .image, figure.image, .kore-image).img-cover :is(.kore-image, img) {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
}

:is(.kore-image-figure, .image, figure.image, .kore-image):is(.ratio-1-1, .aspect-1-1, [data-ratio="1/1"]) { aspect-ratio: 1 / 1; }
:is(.kore-image-figure, .image, figure.image, .kore-image):is(.ratio-16-9, .aspect-16-9, [data-ratio="16/9"]) { aspect-ratio: 16 / 9; }
:is(.kore-image-figure, .image, figure.image, .kore-image):is(.ratio-4-3, .aspect-4-3, [data-ratio="4/3"]) { aspect-ratio: 4 / 3; }
:is(.kore-image-figure, .image, figure.image, .kore-image):is(.ratio-3-4, .aspect-3-4, [data-ratio="3/4"]) { aspect-ratio: 3 / 4; }
:is(.kore-image-figure, .image, figure.image, .kore-image):is(.ratio-21-9, .aspect-21-9, [data-ratio="21/9"]) { aspect-ratio: 21 / 9; }

.kore-image-wrap {
  display: block;
  position: relative;
  width: 100%;
  height: auto;
  overflow: hidden;
  border-radius: inherit;
  text-decoration: none;
  color: inherit;
}

:is(.kore-image-figure, .image, figure.image, .kore-image):is([class*="ratio-"], [class*="aspect-"], [data-ratio]:not([data-ratio="auto"]), .img-cover, .avatar, [class*="avatar-"]) .kore-image-wrap {
  position: absolute;
  inset: 0;
  height: 100%;
}

:is(.kore-image-figure, .image, figure.image, .kore-image):is([class*="ratio-"], [class*="aspect-"], [data-ratio]:not([data-ratio="auto"]), .img-cover, .avatar, [class*="avatar-"]) :is(.kore-picture, picture, .kore-picture-auto, img) {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.kore-picture {
display: block;
width: 100%;
height: 100%;
}

.kore-image, .kore-picture img {
display: block;
width: 100%;
height: 100%;
transition: transform var(--motion) cubic-bezier(0.16, 1, 0.3, 1), filter 0.3s ease;
}

:is(.kore-image, .image, .kore-picture img).object-cover { object-fit: cover; }
:is(.kore-image, .image, .kore-picture img).object-contain { object-fit: contain; }
:is(.kore-image, .image, .kore-picture img).object-fill { object-fit: fill; }

:is(.kore-image-figure, .kore-image):is(.has-glow, .is-glow, [data-glow="true"])::after {
content: '';
position: absolute;
inset: 0;
border-radius: inherit;
box-shadow: inset 0 0 0 0.0625rem var(--surface-border);
z-index: 10;
pointer-events: none;
}

:is(.kore-image-figure, .kore-image):is(.has-dim, .is-dim, [data-dim="true"])::before {
content: '';
position: absolute;
inset: 0;
background: oklch(0% 0 0);
opacity: 0.15;
z-index: 5;
transition: opacity var(--motion) ease;
pointer-events: none;
}

:is(.kore-image-figure, .kore-image):is(.has-dim, .is-dim, [data-dim="true"]):hover::before {
opacity: 0;
}

:is(.kore-image-figure, .kore-image):is(.is-grayscale, [data-grayscale="true"]) .kore-image,
:is(.kore-image-figure, .kore-image):is(.is-grayscale, [data-grayscale="true"]) .kore-picture img {
filter: grayscale(100%);
transition: filter var(--motion) ease;
}

:is(.kore-image-figure, .kore-image):is(.is-grayscale, [data-grayscale="true"]):hover .kore-image,
:is(.kore-image-figure, .kore-image):is(.is-grayscale, [data-grayscale="true"]):hover .kore-picture img {
filter: grayscale(0%);
}

.kore-image-overlay {
position: absolute;
inset: 0;
background: oklch(33.5% var(--brand-c) var(--brand-h) / var(--local-overlay, 0%));
z-index: 1;
pointer-events: none;
mix-blend-mode: multiply;
}

a.kore-image-wrap {
transition: var(--motion);
}

a.kore-image-wrap:hover .kore-image {
transform: var(--local-transform-hover, translateY(-1px));
}

a.kore-image-wrap:focus-visible {
outline: var(--local-outline-focus, var(--border-width) solid var(--local-intent-color, var(--brand)));
outline-offset: 0.125rem;
}

a.kore-image-wrap:active .kore-image {
transform: var(--local-transform-active, scale(0.98));
}

:is(.kore-image-figure, .kore-image):is(.shadow-idle, [data-shadow="shadow-idle"]) {
box-shadow: var(--shadow-md);
transition: box-shadow var(--motion) ease;
}

:is(.kore-image-figure, .kore-image):is(.shadow-hover, [data-shadow="shadow-hover"]) {
box-shadow: var(--shadow-md);
transition: box-shadow var(--motion) var(--motion), transform var(--motion) ease;
}

:is(.kore-image-figure, .kore-image):is(.shadow-hover, [data-shadow="shadow-hover"]):hover {
box-shadow: var(--shadow-md);
transform: var(--local-transform-hover, translateY(-0.125rem));
}

.kore-image-caption {
position: absolute;
inset-inline: 0;
bottom: 0;
padding: var(--space-xs) var(--space-xs);
z-index: 20;
text-align: center;
font-size: var(--font-size-sm);
font-weight: var(--font-weight-semibold);
backdrop-filter: blur(12px);
-webkit-backdrop-filter: blur(12px);


background: var(--local-caption-bg, var(--surface-elevated));
color: var(--local-caption-text, var(--local-color, var(--text-main)));
}

.kore-image-caption.text-is-brand         { color: var(--brand); }
.kore-image-caption.text-is-accent        { color: var(--brand-accent); }
.kore-image-caption.text-is-text-main  { color: var(--text-main); }
.kore-image-caption.text-is-text-inv      { color: var(--text-main); }
.kore-image-caption.text-is-text-muted { color: var(--text-muted); }

.kore-image-caption.is-transparent {
background: transparent;
backdrop-filter: none;
-webkit-backdrop-filter: none;
text-shadow: 0 0.0625rem 0.1875rem oklch(0% 0 0 / 60%);
}

:is(.kore-image-figure, .kore-image):is(.is-placeholder, [data-placeholder="true"]) {
background-color: var(--canvas);
border: var(--border-width) dashed var(--surface-border);
display: grid;
place-items: center;
min-height: 12.5rem;
background-image: radial-gradient(var(--surface-border) 0.0625rem, transparent 0.0625rem);
background-size: 1.25rem 1.25rem;
border-radius: var(--local-radius, 0);
color: var(--text-muted);
}

.kore-image-placeholder {
width: 100%;
height: 100%;
min-height: 12.5rem;
display: flex;
align-items: center;
justify-content: center;
background: linear-gradient(135deg, var(--surface-subtle, oklch(0% 0 0)), var(--surface, oklch(0% 0 0)));
color: var(--text-muted);
border-radius: inherit;
}
.kore-image-placeholder svg {
width: 3.5rem;
height: 3.5rem;
opacity: 0.15;
transition: opacity 0.3s ease, transform 0.3s ease;
}
.kore-image-wrap:hover .kore-image-placeholder svg {
opacity: 0.3;
transform: scale(1.1);
}

/* ==========================================================================
   KORE_IMAGE MODIFIERS — LOGO & BRAND ASSETS (.logo-img, .logo-link)
   Single Source of Truth: go-admin/src/Elements/GoAdmin_Image/default.css
   ========================================================================== */

:is(.kore-image-figure, .image, figure.image, .kore-image).logo-img {
  width: auto;
  max-width: var(--local-logo-max-w, 10rem);
  height: var(--local-logo-h, 2.25rem);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
  background-color: transparent;
  flex-shrink: 0;
  box-shadow: none;
}

:is(.kore-image-figure, .image, figure.image, .kore-image).logo-img .kore-image-wrap {
  width: auto;
  height: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
}

:is(.kore-image-figure, .image, figure.image, .kore-image).logo-img .kore-picture {
  width: auto;
  height: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

:is(.kore-image-figure, .image, figure.image, .kore-image).logo-img :is(.kore-image, img) {
  width: auto;
  max-width: 100%;
  height: 100%;
  max-height: 100%;
  object-fit: contain !important;
  filter: none;
  mix-blend-mode: normal;
  background-color: transparent;
}

@media (min-width: 48rem) {
  :is(.kore-image-figure, .image, figure.image, .kore-image).logo-img {
    height: var(--local-logo-h-md, 2.75rem);
    max-width: var(--local-logo-max-w-md, 12rem);
  }
}

:is(.stage-dark, .bg-dark, [data-theme="dark"]) :is(.kore-image-figure, .image, figure.image, .kore-image).logo-img :is(.kore-image, img) {
  filter: brightness(0) invert(1);
}

.logo-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: opacity var(--duration-fast, 0.15s) ease, transform var(--duration-fast, 0.15s) ease;
}

.logo-link:hover {
  opacity: 0.8;
  transform: translateY(-1px);
}

