.arcane-codex-entry-layout {
    box-sizing: border-box;
    width: 100%;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: var(--ac-section-gap, 18px);
    transform-origin: top center;
    color: var(--ac-primary-ink, #2f241e);
    font-family: var(--ac-body-font, Georgia, serif);
    font-size: var(--ac-body-size, 17px);
    font-weight: var(--ac-body-weight, 400);
    line-height: var(--ac-body-line-height, 1.58);
    background: transparent;
}
.arcane-codex-entry-layout *, .arcane-codex-entry-layout *::before, .arcane-codex-entry-layout *::after { box-sizing: border-box; }
.arcane-codex-entry-layout__heading { text-align: center; }
.arcane-codex-entry-layout__title {
    margin: 0;
    font-family: var(--ac-title-font, Georgia, serif);
    font-size: var(--ac-title-size, 58px);
    font-weight: var(--ac-title-weight, 600);
    letter-spacing: var(--ac-title-spacing, 2px);
    line-height: .98;
    color: var(--ac-primary-ink, #2f241e);
}
.arcane-codex-entry-layout__scientific {
    margin-top: 5px;
    font-family: var(--ac-scientific-font, Georgia, serif);
    font-size: var(--ac-scientific-size, 22px);
    font-weight: var(--ac-scientific-weight, 400);
    color: var(--ac-secondary-ink, #49372d);
    font-style: italic;
}
.arcane-codex-entry-layout__overview {
    display: grid;
    grid-template-columns: minmax(0, var(--ac-overview-left, 44%)) minmax(0, var(--ac-overview-right, 56%));
    gap: var(--ac-overview-gap, 26px);
    align-items: center;
}
.arcane-codex-entry-layout__correspondence-area { min-width: 0; display: grid; align-content: center; justify-items: center; gap: 10px; }
.arcane-codex-entry-layout__correspondences {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, var(--ac-badge-size, 138px)));
    justify-content: center;
    align-content: center;
    column-gap: var(--ac-badge-gap-x, 8px);
    row-gap: var(--ac-badge-gap-y, 6px);
}
.arcane-codex-entry-layout__badge { position: relative; width: var(--ac-badge-size, 138px); max-width: 100%; aspect-ratio: 1 / 1; min-width: 0; display: grid; place-items: center; }
.arcane-codex-entry-layout__badge-frame { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; pointer-events: none; }
.arcane-codex-entry-layout__badge-content { position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; text-align: center; }
.arcane-codex-entry-layout__badge-label { position:absolute; top:var(--ac-badge-label-y,20%); left:50%; transform:translate(-50%,-50%); width:74%; font-family: var(--ac-section-font, Georgia, serif); font-size: .66em; font-weight: 600; letter-spacing: .07em; text-transform: uppercase; color: var(--ac-secondary-ink, #49372d); }
.arcane-codex-entry-layout__badge-icon { position:absolute; top:var(--ac-badge-icon-y,49%); left:50%; transform:translate(-50%,-50%); width:var(--ac-badge-icon-size,25%); max-height:var(--ac-badge-icon-size,25%); object-fit:contain; }
.arcane-codex-entry-layout__badge-glyph { position:absolute; top:var(--ac-badge-icon-y,49%); left:50%; transform:translate(-50%,-50%); font-size:var(--ac-badge-icon-font-size,34.5px); line-height:1; color: var(--ac-frame-ink, #17100c); }
.arcane-codex-entry-layout__badge-value { position:absolute; top:var(--ac-badge-value-y,78%); left:50%; transform:translate(-50%,-50%); width:76%; font-size:.78em; font-weight:600; line-height:1.05; color:var(--ac-primary-ink,#2f241e); }
.arcane-codex-entry-layout__image-wrap { position: relative; width: 100%; aspect-ratio: var(--ac-image-ratio, 16 / 9); overflow: hidden; border-radius: var(--ac-image-radius, 8px); }
.arcane-codex-entry-layout__image { width: 100%; height: 100%; display: block; object-fit: var(--ac-image-fit, contain); object-position: var(--ac-image-focal-x, 50%) var(--ac-image-focal-y, 50%); }
.arcane-codex-entry-layout__image-placeholder { width: 100%; height: 100%; display: grid; place-items: center; border: 1px solid rgba(47,36,30,.28); color: var(--ac-secondary-ink, #49372d); font-size: 36px; }
.arcane-codex-entry-layout__properties { position: relative; min-height: 54px; display: grid; place-items: center; padding: 10px 24px; }
.arcane-codex-entry-layout__properties-frame { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: fill; pointer-events: none; }
.arcane-codex-entry-layout__properties-content { position: relative; z-index: 1; display: flex; align-items: baseline; justify-content: center; flex-wrap: wrap; gap: 8px; width: 92%; text-align: center; font-family: var(--ac-property-font, Georgia, serif); font-size: var(--ac-property-size, 14px); font-weight: var(--ac-property-weight, 700); color: var(--ac-primary-ink, #2f241e); }
.arcane-codex-entry-layout__properties-label { color: var(--ac-secondary-ink, #49372d); }
.arcane-codex-entry-layout__properties-list { display: inline-flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 7px; text-transform: uppercase; letter-spacing: .04em; }
.arcane-codex-entry-layout__property-separator { color: var(--ac-accent-ink, #72513e); }
.arcane-codex-entry-layout__horizontal-divider { height: 30px; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.arcane-codex-entry-layout__horizontal-divider img { display: block; max-width: 68%; width: 100%; max-height: 100%; object-fit: contain; }
.arcane-codex-entry-layout__split { display: grid; grid-template-columns: minmax(0, var(--ac-split-left, 50%)) 28px minmax(0, var(--ac-split-right, 50%)); gap: var(--ac-split-gap, 22px); align-items: stretch; }
.arcane-codex-entry-layout__text-column { position: relative; min-width: 0; }
.arcane-codex-entry-layout__text-column h2, .arcane-codex-entry-layout__caution h2 { margin: 0 0 8px; font-family: var(--ac-section-font, Georgia, serif); font-size: var(--ac-section-size, 27px); font-weight: var(--ac-section-weight, 600); letter-spacing: var(--ac-section-spacing, 1.4px); text-transform: uppercase; line-height: 1.05; color: var(--ac-primary-ink, #2f241e); }
.arcane-codex-entry-layout__body p { margin: 0 0 .55em; }
.arcane-codex-entry-layout__body p:last-child { margin-bottom: 0; }
.arcane-codex-entry-layout__body .is-empty { opacity: .5; }
.arcane-codex-entry-layout__vertical-divider { min-height: 100%; display: flex; justify-content: center; align-items: stretch; overflow: hidden; }
.arcane-codex-entry-layout__vertical-divider img { width: 100%; height: 100%; max-height: 100%; object-fit: contain; }
.arcane-codex-entry-layout__vertical-rule { width: 1px; justify-self: center; background: var(--ac-divider-ink, #2f241e); opacity: .55; }
.arcane-codex-entry-layout__caution { color: var(--ac-caution-ink, #6f2d2d); font-family: var(--ac-caution-font, Georgia, serif); font-size: var(--ac-caution-size, 15px); font-weight: var(--ac-caution-weight, 400); }
.arcane-codex-entry-layout__caution-heading { display: grid; grid-template-columns: auto 1fr; gap: 14px; align-items: center; }
.arcane-codex-entry-layout__caution-heading h2 { color: var(--ac-caution-ink, #6f2d2d); margin-bottom: 0; }
.arcane-codex-entry-layout__caution-heading span { height: 1px; background: currentColor; opacity: .55; }
.arcane-codex-entry-layout__caution-body { margin-top: 7px; }
.arcane-codex-entry-layout__caution-body p { margin: 0; }

/* Optional illustration slots are semantic, not free-positioned. */
.arcane-codex-entry-layout__ornament-slot { position: relative; z-index: 2; pointer-events: none; }
.arcane-codex-entry-layout__ornament { display: block; object-fit: contain; max-height: 150px; }
.arcane-codex-entry-layout__ornament--small { width: 72px; max-height: 72px; }
.arcane-codex-entry-layout__ornament--medium { width: 104px; max-height: 104px; }
.arcane-codex-entry-layout__ornament--large { width: 142px; max-height: 142px; }
.arcane-codex-entry-layout__ornament-slot--overview-left { justify-self: center; margin-top: -6px; }
.arcane-codex-entry-layout__ornament-slot--overview-right { position: absolute; right: 10px; bottom: 10px; }
.arcane-codex-entry-layout__ornament-slot--between { display: flex; justify-content: center; margin-top: -8px; margin-bottom: -8px; }
.arcane-codex-entry-layout__ornament-slot--uses { float: right; margin: 0 0 6px 12px; }
.arcane-codex-entry-layout__ornament-slot--practice { float: left; margin: 0 12px 6px 0; }
.arcane-codex-entry-layout__ornament-slot--bottom { display: flex; justify-content: center; margin-top: -8px; }

/* Template editor uses the exact server-rendered entry markup over parchment. */
.arcane-codex-entry-layout-preview { width: 100%; background: transparent; }
.arcane-codex-entry-layout-preview .components-placeholder { background: transparent; border: 0; box-shadow: none; padding: 0; min-height: 0; }
.arcane-codex-entry-layout-preview__empty { padding: 18px; border: 1px dashed #8c8f94; background: rgba(255,255,255,.5); color: #50575e; text-align: center; }
.arcane-codex-entry-layout-preview.has-section-guides .arcane-codex-entry-layout__heading,
.arcane-codex-entry-layout-preview.has-section-guides .arcane-codex-entry-layout__overview,
.arcane-codex-entry-layout-preview.has-section-guides .arcane-codex-entry-layout__properties,
.arcane-codex-entry-layout-preview.has-section-guides .arcane-codex-entry-layout__horizontal-divider,
.arcane-codex-entry-layout-preview.has-section-guides .arcane-codex-entry-layout__split,
.arcane-codex-entry-layout-preview.has-section-guides .arcane-codex-entry-layout__caution,
.arcane-codex-entry-layout-preview.has-section-guides .arcane-codex-entry-layout__ornament-slot--between,
.arcane-codex-entry-layout-preview.has-section-guides .arcane-codex-entry-layout__ornament-slot--bottom {
    outline: 1px dashed rgba(72, 102, 135, .5);
    outline-offset: 3px;
}

/* Compact visual language for Inspector controls. */
.ac-layout-control-group { padding: 0 0 16px; margin: 0 0 16px; border-bottom: 1px solid #e0e0e0; }
.ac-layout-control-group:last-child { border-bottom: 0; margin-bottom: 0; padding-bottom: 0; }
.ac-layout-control-group > strong { display: block; margin-bottom: 8px; }
.ac-layout-map { width: 100%; margin: 0 0 12px; border: 1px solid #c9c4bd; background: #f8f5ef; border-radius: 4px; color: #5a5148; font-size: 9px; }
.ac-layout-map--overview { height: 54px; display: flex; gap: 0; padding: 7px; }
.ac-layout-map--overview span { display: grid; place-items: center; border: 1px dashed #9d9185; min-width: 0; }
.ac-layout-map--overview span.is-image { flex: 1; background: rgba(96,122,145,.08); }
.ac-layout-map--overview i { flex: 0 0 auto; }
.ac-layout-map--badges { display: grid; grid-template-columns: 1fr 1fr; padding: 8px 24%; }
.ac-layout-map--badges span { aspect-ratio: 1; border: 1px dashed #9d9185; border-radius: 50%; }
.ac-layout-map--split { height: 50px; display: flex; gap: 7px; align-items: stretch; padding: 7px; }
.ac-layout-map--split span { display: grid; place-items: center; border: 1px dashed #9d9185; min-width: 0; flex: 1; }
.ac-layout-map--split i { width: 1px; background: #76685c; }
.ac-layout-map--rhythm { min-height: 64px; display: flex; flex-direction: column; padding: 8px 18%; }
.ac-layout-map--rhythm span { display: block; height: 8px; border: 1px dashed #9d9185; background: rgba(255,255,255,.55); }
.ac-layout-map--image { height: 84px; display: grid; place-items: center; padding: 8px; }
.ac-layout-map--image span { display: grid; place-items: center; width: 66%; border: 1px dashed #9d9185; background: rgba(96,122,145,.08); }
.ac-layout-map--image.ratio-1-1 span { aspect-ratio: 1; width: 38%; }
.ac-layout-map--image.ratio-4-3 span { aspect-ratio: 4 / 3; width: 52%; }
.ac-layout-map--image.ratio-3-2 span { aspect-ratio: 3 / 2; width: 58%; }
.ac-layout-map--image.ratio-16-9 span { aspect-ratio: 16 / 9; width: 68%; }
.ac-layout-map--ornament { position: relative; display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 34px 20px 34px 18px; gap: 4px; padding: 6px; min-height: 120px; }
.ac-layout-map--ornament .zone { display: grid; place-items: center; border: 1px dashed #aaa098; }
.ac-layout-map--ornament .zone-properties { grid-column: 1 / 3; }
.ac-layout-map--ornament .zone-bottom { grid-column: 1 / 3; }
.ac-layout-map--ornament b { position: absolute; padding: 3px 5px; border-radius: 3px; background: #674d3f; color: #fff; font-size: 8px; line-height: 1; }
.ac-layout-map--ornament.ac-ornament-pos-overview-left b { top: 24px; left: 22%; }
.ac-layout-map--ornament.ac-ornament-pos-overview-right b { top: 24px; right: 12%; }
.ac-layout-map--ornament.ac-ornament-pos-between b { top: 56px; left: 42%; }
.ac-layout-map--ornament.ac-ornament-pos-uses b { top: 84px; left: 18%; }
.ac-layout-map--ornament.ac-ornament-pos-practice b { top: 84px; right: 12%; }
.ac-layout-map--ornament.ac-ornament-pos-bottom b { bottom: 5px; left: 42%; }

@media (max-width: 720px) {
    .arcane-codex-entry-layout__overview { grid-template-columns: 1fr; }
    .arcane-codex-entry-layout__split { grid-template-columns: 1fr; }
    .arcane-codex-entry-layout__vertical-divider, .arcane-codex-entry-layout__vertical-rule { display: none; }
}

/* 0.7.0 safe-area fitting */
.ptx-codex-sheet__content { overflow: hidden; }
.arcane-codex-entry-layout.is-auto-fitted { will-change: transform; }

/* 0.8.0 restrained manuscript accents */
.arcane-codex-entry-layout__properties {
    width: 96%;
    min-height: 72px;
    align-self: center;
    padding: 14px 34px;
}
.arcane-codex-entry-layout__properties-content { width: 90%; }
.arcane-codex-entry-layout__horizontal-divider {
    width: 84%;
    height: 42px;
    align-self: center;
    margin-top: -8px;
    margin-bottom: -8px;
}
.arcane-codex-entry-layout__horizontal-divider img { max-width: 100%; width: 100%; max-height: 100%; object-fit: contain; }
.arcane-codex-entry-layout__text-column > h2::after {
    content: '';
    display: block;
    width: min(42%, 180px);
    height: 7px;
    margin-top: 8px;
    margin-bottom: 12px;
    background: var(--ac-primary-ink, #2f241e);
    clip-path: polygon(0 0, 100% 46%, 100% 54%, 0 100%);
}
.arcane-codex-entry-layout__vertical-rule { opacity: 1; }
.arcane-codex-entry-layout__vertical-divider img { opacity: 1; }

/* 0.9.1 composed correspondence cluster + deterministic accents */
.arcane-codex-entry-layout__correspondence-area {
    overflow: visible;
}
.arcane-codex-entry-layout__correspondences {
    width: max-content;
    max-width: 100%;
    display: grid;
    grid-template-columns: repeat(2, var(--ac-badge-slot-size, 170px));
    grid-template-rows: repeat(2, var(--ac-badge-slot-size, 170px));
    column-gap: 0;
    row-gap: 0;
    justify-content: center;
    align-content: center;
}
.arcane-codex-entry-layout__badge {
    position: relative;
    width: var(--ac-badge-slot-size, 170px);
    height: var(--ac-badge-slot-size, 170px);
    max-width: none;
    aspect-ratio: auto;
    display: grid;
    place-items: center;
}
.arcane-codex-entry-layout__badge:nth-child(even) {
    margin-left: var(--ac-badge-gap-x, -14px);
}
.arcane-codex-entry-layout__badge:nth-child(n+3) {
    margin-top: var(--ac-badge-gap-y, -12px);
}
.arcane-codex-entry-layout__badge-frame,
.arcane-codex-entry-layout__badge-content {
    position: absolute;
    inset: auto;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: var(--ac-badge-frame-size, 159px);
    height: var(--ac-badge-frame-size, 159px);
}
.arcane-codex-entry-layout__badge-frame {
    object-fit: contain;
    pointer-events: none;
}
.arcane-codex-entry-layout__badge-content {
    z-index: 1;
    text-align: center;
    font-size: calc(var(--ac-body-size, 17px) * var(--ac-badge-content-scale, 1));
}
.arcane-codex-entry-layout__badge-label {
    font-size: .66em;
}
.arcane-codex-entry-layout__badge-value {
    font-size: .78em;
}
.arcane-codex-entry-layout__badge-icon {
    width: var(--ac-badge-icon-size, 25%);
    max-height: var(--ac-badge-icon-size, 25%);
}

/* A properties plate is a region, never a shrink-to-content ornament. */
.arcane-codex-entry-layout__properties {
    width: 98%;
    min-height: 84px;
    height: auto;
    align-self: center;
    padding: 17px 44px;
    overflow: visible;
}
.arcane-codex-entry-layout__properties-frame {
    inset: 0;
    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;
    object-fit: fill;
}
.arcane-codex-entry-layout__properties-content {
    width: 92%;
    max-width: none;
}

/* Divider artwork fills its semantic corridor instead of preserving old intrinsic sizing. */
.arcane-codex-entry-layout__horizontal-divider {
    width: 76%;
    height: 38px;
    align-self: center;
    margin-top: -10px;
    margin-bottom: -5px;
    overflow: visible;
}
.arcane-codex-entry-layout__horizontal-divider img {
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;
    object-fit: fill;
}
.arcane-codex-entry-layout__split {
    grid-template-columns: minmax(0, var(--ac-split-left, 50%)) 26px minmax(0, var(--ac-split-right, 50%));
}
.arcane-codex-entry-layout__vertical-divider {
    width: 26px;
    min-height: 100%;
    height: 100%;
    align-self: stretch;
    overflow: visible;
}
.arcane-codex-entry-layout__vertical-divider img {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 100%;
    max-width: none;
    max-height: none;
    object-fit: fill;
    opacity: 1;
}
.arcane-codex-entry-layout__vertical-rule {
    height: 100%;
    opacity: 1;
}

/* Restrained manuscript heading accent: heavy at origin, tapering to a point. */
.arcane-codex-entry-layout__text-column > h2::after {
    content: '';
    display: block;
    width: min(40%, 210px);
    height: 8px;
    margin-top: 8px;
    margin-bottom: 12px;
    background: var(--ac-primary-ink, #2f241e);
    clip-path: polygon(0 0, 0 100%, 100% 50%);
}
.arcane-codex-entry-layout__badge-content {
    width: var(--ac-badge-content-size, 159px);
    height: var(--ac-badge-content-size, 159px);
}
.arcane-codex-entry-layout__badge-icon {
    width: var(--ac-badge-icon-render-size, 40px);
    height: var(--ac-badge-icon-render-size, 40px);
    max-height: none;
}
.arcane-codex-entry-layout__badge-glyph {
    font-size: var(--ac-badge-icon-render-size, 40px);
}

/* 0.9.2 — overview regions are edge-anchored and badge composition cannot resize the row. */
.arcane-codex-entry-layout__overview {
    grid-template-columns: minmax(0, var(--ac-overview-left, 44fr)) minmax(0, var(--ac-overview-right, 56fr));
    gap: 0;
    align-items: stretch;
}
.arcane-codex-entry-layout__correspondence-area {
    position: relative;
    min-width: 0;
    min-height: 0;
    height: 100%;
    overflow: hidden;
    display: block;
}
.arcane-codex-entry-layout__correspondences {
    position: absolute;
    left: 0;
    top: 50%;
    width: calc(var(--ac-badge-slot-size, 170px) + var(--ac-badge-slot-size, 170px) + var(--ac-badge-gap-x, -14px));
    height: calc(var(--ac-badge-slot-size, 170px) + var(--ac-badge-slot-size, 170px) + var(--ac-badge-gap-y, -12px));
    min-width: 1px;
    min-height: 1px;
    display: block;
    max-width: none;
    transform: translateY(-50%) scale(var(--ac-badge-fit, 1));
    transform-origin: left center;
}
.arcane-codex-entry-layout__badge {
    position: absolute;
    width: var(--ac-badge-slot-size, 170px);
    height: var(--ac-badge-slot-size, 170px);
    margin: 0 !important;
}
.arcane-codex-entry-layout__badge:nth-child(1) { left: 0; top: 0; }
.arcane-codex-entry-layout__badge:nth-child(2) { left: calc(var(--ac-badge-slot-size, 170px) + var(--ac-badge-gap-x, -14px)); top: 0; }
.arcane-codex-entry-layout__badge:nth-child(3) { left: 0; top: calc(var(--ac-badge-slot-size, 170px) + var(--ac-badge-gap-y, -12px)); }
.arcane-codex-entry-layout__badge:nth-child(4) { left: calc(var(--ac-badge-slot-size, 170px) + var(--ac-badge-gap-x, -14px)); top: calc(var(--ac-badge-slot-size, 170px) + var(--ac-badge-gap-y, -12px)); }
.arcane-codex-entry-layout__image-wrap {
    width: 92%;
    justify-self: end;
    align-self: center;
}

/* Fixed semantic accent regions; assets fill the region and never size the manuscript. */
.arcane-codex-entry-layout__properties {
    width: 100%;
    min-height: 74px;
    height: 74px;
    align-self: stretch;
    padding: 12px 40px;
    overflow: hidden;
}
.arcane-codex-entry-layout__properties-frame {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;
    object-fit: fill;
}
.arcane-codex-entry-layout__properties-content {
    width: 94%;
    max-width: none;
    margin: auto;
}
.arcane-codex-entry-layout__horizontal-divider {
    width: 72%;
    height: 30px;
    align-self: center;
    margin: -4px auto -2px;
    overflow: hidden;
}
.arcane-codex-entry-layout__horizontal-divider img {
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;
    object-fit: fill;
}
.arcane-codex-entry-layout__split {
    grid-template-columns: minmax(0, var(--ac-split-left, 50fr)) 22px minmax(0, var(--ac-split-right, 50fr));
    gap: var(--ac-split-gap, 16px);
    align-items: stretch;
}
.arcane-codex-entry-layout__vertical-divider {
    width: 22px;
    height: 100%;
    min-height: 100%;
    align-self: stretch;
    overflow: hidden;
}
.arcane-codex-entry-layout__vertical-divider img {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 100%;
    max-width: none;
    max-height: none;
    object-fit: fill;
    opacity: 1;
}
.arcane-codex-entry-layout__vertical-rule { height: 100%; opacity: 1; }

/* Thick-at-start, pointed-at-end manuscript heading accents. */
.arcane-codex-entry-layout__text-column > h2::after {
    width: min(42%, 220px);
    height: 7px;
    margin-top: 7px;
    margin-bottom: 11px;
    clip-path: polygon(0 0, 100% 50%, 0 100%);
}

/* 0.9.4 — dynamic, non-distorting Magical Properties frame.
 *
 * The properties plate is content-driven: more Magical Properties wrap onto
 * additional lines and increase the section height naturally. The bundled
 * frame is composed from fixed-aspect ornamental slices plus CSS edge rules,
 * so corners/flourishes never get squashed when the plate grows.
 */
.arcane-codex-entry-layout__properties {
    position: relative;
    width: 94%;
    min-height: 74px;
    height: auto;
    align-self: center;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px clamp(54px, 5.2vw, 78px) 20px;
    overflow: visible;
}
.arcane-codex-entry-layout__properties-content {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: none;
    margin: 0;
}

/* Default frame: ornamental pieces retain their own aspect ratios while the
 * straight edges are generated independently and can grow to any height. */
.arcane-codex-entry-layout__properties-frame--sliced {
    position: absolute;
    inset: 0;
    z-index: 0;
    display: block;
    width: auto;
    height: auto;
    pointer-events: none;
    color: var(--ac-frame-ink, var(--ac-primary-ink, #2f241e));
}
.arcane-codex-entry-layout__frame-line {
    position: absolute;
    z-index: 0;
    display: block;
    background: currentColor;
    opacity: .96;
}
.arcane-codex-entry-layout__frame-line--top {
    top: 8px;
    left: 48px;
    right: 48px;
    height: 1px;
}
.arcane-codex-entry-layout__frame-line--right {
    top: 30px;
    right: 8px;
    bottom: 30px;
    width: 1px;
}
.arcane-codex-entry-layout__frame-line--bottom {
    right: 48px;
    bottom: 8px;
    left: 78px;
    height: 1px;
}
.arcane-codex-entry-layout__frame-line--left {
    top: 30px;
    bottom: 30px;
    left: 8px;
    width: 1px;
}
.arcane-codex-entry-layout__frame-part {
    position: absolute;
    z-index: 1;
    display: block;
    background: currentColor;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-size: contain;
    mask-size: contain;
    pointer-events: none;
}
.arcane-codex-entry-layout__frame-part--top-left {
    top: 0;
    left: 0;
    width: 58px;
    height: 40px;
    -webkit-mask-image: url('../images/keyword-frame-top-left.png');
    mask-image: url('../images/keyword-frame-top-left.png');
    -webkit-mask-position: left top;
    mask-position: left top;
}
.arcane-codex-entry-layout__frame-part--top-center {
    top: 1px;
    left: 50%;
    width: 43px;
    height: 13px;
    transform: translateX(-50%);
    -webkit-mask-image: url('../images/keyword-frame-top-center.png');
    mask-image: url('../images/keyword-frame-top-center.png');
    -webkit-mask-position: center top;
    mask-position: center top;
}
.arcane-codex-entry-layout__frame-part--top-right {
    top: 0;
    right: 0;
    width: 57px;
    height: 40px;
    -webkit-mask-image: url('../images/keyword-frame-top-right.png');
    mask-image: url('../images/keyword-frame-top-right.png');
    -webkit-mask-position: right top;
    mask-position: right top;
}
.arcane-codex-entry-layout__frame-part--bottom-left {
    bottom: 0;
    left: 0;
    width: 82px;
    height: 43px;
    -webkit-mask-image: url('../images/keyword-frame-bottom-left.png');
    mask-image: url('../images/keyword-frame-bottom-left.png');
    -webkit-mask-position: left bottom;
    mask-position: left bottom;
}
.arcane-codex-entry-layout__frame-part--bottom-center {
    bottom: 1px;
    left: 50%;
    width: 43px;
    height: 13px;
    transform: translateX(-50%);
    -webkit-mask-image: url('../images/keyword-frame-bottom-center.png');
    mask-image: url('../images/keyword-frame-bottom-center.png');
    -webkit-mask-position: center bottom;
    mask-position: center bottom;
}
.arcane-codex-entry-layout__frame-part--bottom-right {
    right: 0;
    bottom: 0;
    width: 50px;
    height: 43px;
    -webkit-mask-image: url('../images/keyword-frame-bottom-right.png');
    mask-image: url('../images/keyword-frame-bottom-right.png');
    -webkit-mask-position: right bottom;
    mask-position: right bottom;
}

/* Uploaded/custom frame assets are retained for compatibility. They no
 * longer force the properties section to a fixed height. */
.arcane-codex-entry-layout__properties-frame--custom {
    position: absolute;
    inset: 0;
    z-index: 0;
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;
    object-fit: fill;
    pointer-events: none;
}

/* Divider corridors remain deterministic and independent of source art. */
.arcane-codex-entry-layout__horizontal-divider {
    position: relative;
    width: 70%;
    height: 38px;
    flex: 0 0 38px;
    align-self: center;
    margin: -9px auto -3px;
    overflow: visible;
}
.arcane-codex-entry-layout__horizontal-divider img {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;
    object-fit: fill;
}

.arcane-codex-entry-layout__split {
    grid-template-columns: minmax(0, var(--ac-split-left, 50fr)) 28px minmax(0, var(--ac-split-right, 50fr));
    gap: var(--ac-split-gap, 16px);
    align-items: stretch;
}
.arcane-codex-entry-layout__vertical-divider {
    position: relative;
    width: 28px;
    min-width: 28px;
    min-height: 0;
    height: auto;
    align-self: stretch;
    justify-self: center;
    overflow: visible;
}
.arcane-codex-entry-layout__vertical-divider img {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    min-height: 0;
    max-width: none;
    max-height: none;
    object-fit: fill;
    opacity: 1;
}

@media (max-width: 720px) {
    .arcane-codex-entry-layout__properties {
        width: 100%;
        padding: 18px 48px 20px;
    }
    .arcane-codex-entry-layout__frame-part--bottom-left {
        width: 70px;
        height: 37px;
    }
    .arcane-codex-entry-layout__horizontal-divider {
        width: 78%;
    }
}

