/*
 * Design System admin styles. Visual vocabulary mirrors the Configuration
 * page (card-based sections, white background, 1px #c3c4c7 border, 6px
 * radius, subtle drop shadow) so the Novamira admin feels cohesive across
 * pages. The page chrome is WordPress-native; only the specimens (the
 * preview mini-UI, palette, type samples, components) wear the design's
 * own tokens via the --nd-* custom properties.
 */

.novamira-design {
    --ds-mono: ui-monospace, "DM Mono", "JetBrains Mono", Consolas, monospace;
    max-width: 1180px;
}

.novamira-design-intro {
    color: #50575e;
    font-size: 14px;
    line-height: 1.6;
    margin: 4px 0 24px;
}

/* ── Gallery of design systems. ──────────────────────────────────────────── */
.novamira-design-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(540px, 1fr));
    gap: 20px;
    margin: 0 0 28px;
}
@media (max-width: 1160px) {
    .novamira-design-gallery {
        grid-template-columns: 1fr;
    }
}
.novamira-design-card2 {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid #c3c4c7;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.03);
    transition: border-color 0.1s ease;
}
.novamira-design-card2:hover {
    border-color: #a7aaad;
}
.novamira-design-card2.is-active {
    border-color: #2271b1;
    box-shadow: 0 0 0 1px #2271b1;
}
.novamira-design-stage {
    display: block;
    text-decoration: none;
    padding: 16px 16px 0;
}
.novamira-design-card2-body {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 16px 24px 20px;
}
.novamira-design-card2-head {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}
.novamira-design-card2-head h2 {
    font-size: 18px;
    font-weight: 600;
    color: #1d2327;
    margin: 0;
    padding: 0;
}
.novamira-design-card2-head h2 a {
    color: inherit;
    text-decoration: none;
}
.novamira-design-card2-head h2 a:hover {
    color: #2271b1;
}
.novamira-design-card2-body .novamira-design-desc {
    margin: 0;
}
.novamira-design-card2-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 2px;
}
.novamira-design-card2-actions form {
    margin: 0;
}

/* Active badge — same pill language as the Skills page. */
.novamira-design-active-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.2px;
    background: #e7f5e9;
    color: #1f6f30;
}

.novamira-design-incomplete-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.2px;
    background: #fcf0d9;
    color: #8a4b08;
}

.novamira-design-desc {
    color: #646970;
    font-size: 13px;
    line-height: 1.55;
}

/* Waivers the design's declarations grant to the anti-slop pre-flight. */
.novamira-design-allows {
    display: inline-flex;
    align-items: center;
    align-self: flex-start;
    padding: 2px 8px;
    border-radius: 3px;
    background: #f4f4f5;
    color: #52525b;
    font-size: 11px;
    font-weight: 500;
}
.nd-detail-headmain .novamira-design-allows {
    margin-top: 8px;
}
.novamira-design-allows-help {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 14px;
    height: 14px;
    margin-left: 6px;
    border-radius: 50%;
    background: #d4d4d8;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    line-height: 1;
    cursor: help;
}

.novamira-design-empty {
    text-align: center;
    padding: 48px 24px;
    margin: 0 0 20px;
    background: #fff;
    border: 1px solid #c3c4c7;
    border-radius: 6px;
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.03);
}
.novamira-design-empty p {
    margin: 0;
    color: #50575e;
    font-size: 14px;
    line-height: 1.6;
}

/* ── Detail page: the full anatomy of one design system. ─────────────────── */
.novamira-design-detail {
    max-width: 1080px;
}
.nd-detail-back {
    display: inline-block;
    margin: 8px 0 16px;
    font-size: 13px;
    color: #2271b1;
    text-decoration: none;
}
.nd-detail-back:hover {
    text-decoration: underline;
}
.nd-detail-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}
.nd-detail-kicker {
    display: block;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #71717a;
    margin-bottom: 6px;
}
.nd-detail-title {
    font-size: 23px;
    font-weight: 400;
    line-height: 1.3;
    color: #1d2327;
    margin: 0;
    padding: 0;
}
.nd-detail-desc {
    margin: 8px 0 0;
    color: #646970;
    font-size: 13px;
    line-height: 1.55;
}
.nd-detail-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}
.nd-detail-actions form {
    margin: 0;
}
.nd-detail-stage {
    container-type: inline-size;
    margin-bottom: 20px;
}
.nd-detail-cols {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}
@media (max-width: 900px) {
    .nd-detail-cols {
        grid-template-columns: 1fr;
    }
}
.nd-detail-block {
    background: #fff;
    border: 1px solid #c3c4c7;
    border-radius: 6px;
    padding: 20px 24px;
    margin-bottom: 20px;
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.03);
}
.nd-detail-block h2 {
    font-size: 18px;
    font-weight: 600;
    color: #1d2327;
    margin: 0 0 16px;
    padding: 0;
}
.nd-detail-count {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 3px;
    background: #f4f4f5;
    color: #52525b;
    font-size: 11px;
    font-weight: 500;
    margin-left: 8px;
    vertical-align: middle;
}
.nd-detail-eyebrow {
    display: block;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #71717a;
    margin-bottom: 10px;
}

/* Palette chips. */
.nd-palette {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 12px;
}
.nd-palette-chip {
    display: flex;
    flex-direction: column;
    padding: 8px;
    border: 1px solid #dcdcde;
    border-radius: 4px;
    background: #fff;
}
.nd-palette-swatch {
    height: 48px;
    border-radius: 3px;
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.08);
    margin-bottom: 8px;
}
.nd-palette-name {
    font-size: 12px;
    color: #1d2327;
}
.nd-palette-hex {
    font-family: var(--ds-mono);
    font-size: 11px;
    color: #646970;
}

/* Shape & spacing — radius boxes and spacing bars drawn at real size. */
.nd-shape {
    display: flex;
    align-items: flex-start;
    gap: 32px;
    flex-wrap: wrap;
}
.nd-shape-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}
.nd-shape-group-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #71717a;
}
.nd-radius-row {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}
.nd-radius-spec {
    display: flex;
    flex-direction: column;
    gap: 6px;
    align-items: center;
}
.nd-radius-box {
    width: 72px;
    height: 72px;
    display: block;
    background: var(--nd-bg, #ffffff);
    border: 2px solid var(--nd-accent, #2271b1);
}
.nd-shape-spec-label {
    font-family: var(--ds-mono);
    font-size: 11px;
    color: #646970;
}
.nd-space-rows {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.nd-space-row {
    display: flex;
    align-items: center;
    gap: 8px;
}
.nd-space-num {
    font-family: var(--ds-mono);
    font-size: 11px;
    color: #646970;
    min-width: 34px;
    text-align: right;
}
.nd-space-bar {
    display: block;
    height: 10px;
    max-width: 100%;
    border-radius: 2px;
    background: var(--nd-accent, #2271b1);
}

/* Composition dials. */
.nd-dials {
    display: grid;
    gap: 14px;
}
.nd-dial-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 6px;
}
.nd-dial-label {
    font-size: 13px;
    color: #1d2327;
}
.nd-dial-value {
    font-family: var(--ds-mono);
    font-size: 12px;
    color: #646970;
}
.nd-dial-track {
    height: 8px;
    border-radius: 999px;
    background: #f0f0f1;
    overflow: hidden;
}
.nd-dial-fill {
    display: block;
    height: 100%;
    border-radius: 999px;
    background: #2271b1;
}
.nd-dials-note {
    margin: 4px 0 0;
    font-size: 12px;
    color: #787c82;
}

/* Type specimens — the samples themselves render in the design's fonts. */
.nd-typeset {
    display: flex;
    flex-direction: column;
}
.nd-typespec {
    padding: 16px 0;
    border-bottom: 1px solid #f0f0f1;
}
.nd-typespec:first-child {
    padding-top: 0;
}
.nd-typespec:last-child {
    border-bottom: none;
    padding-bottom: 0;
}
.nd-typespec-meta {
    display: flex;
    align-items: baseline;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 8px;
}
.nd-typespec-meta code {
    font-family: var(--ds-mono);
    font-size: 11px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #646970;
    background: none;
    padding: 0;
}
.nd-typespec-family {
    font-size: 13px;
    color: #1d2327;
}
.nd-typespec-num {
    font-family: var(--ds-mono);
    font-size: 11px;
    color: #a1a1aa;
}
.nd-typespec-sample {
    font-size: clamp(1.7rem, 4vw, 2.8rem);
    line-height: 1.08;
    color: #1d2327;
}

/* Components — rendered entirely in the design's own tokens. */
.nd-components {
    background: var(--nd-bg, #ffffff) !important;
    color: var(--nd-ink, #15171c) !important;
    font-family: var(--nd-font-body, sans-serif) !important;
    border: 1px solid color-mix(in srgb, var(--nd-ink, #15171c) 12%, transparent) !important;
    border-radius: 6px !important;
    padding: clamp(20px, 3vw, 32px) !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 18px !important;
}
.nd-comp-row {
    display: flex !important;
    align-items: center !important;
    gap: 14px !important;
    flex-wrap: wrap !important;
}
.nd-comp-btn {
    font: inherit !important;
    font-weight: 600 !important;
    font-size: 0.92rem !important;
    padding: 11px 20px !important;
    border: 1px solid transparent !important;
    border-radius: var(--nd-radius, 8px) !important;
    cursor: default !important;
}
.nd-comp-primary {
    background: var(--nd-accent, #2271b1) !important;
    color: #fff !important;
}
.nd-comp-secondary {
    background: transparent !important;
    color: var(--nd-ink, #15171c) !important;
    border-color: color-mix(in srgb, var(--nd-ink, #15171c) 26%, transparent) !important;
}
.nd-comp-ghost {
    background: transparent !important;
    color: var(--nd-accent, #2271b1) !important;
    padding: 11px 8px !important;
}
.nd-comp-badge {
    font-size: 0.72rem !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.05em !important;
    padding: 5px 11px !important;
    border-radius: 999px !important;
    background: color-mix(in srgb, var(--nd-accent, #2271b1) 14%, transparent) !important;
    color: color-mix(in srgb, var(--nd-accent, #2271b1) 80%, var(--nd-ink, #15171c)) !important;
}
.nd-components input.nd-comp-input {
    width: 100% !important;
    box-sizing: border-box !important;
    padding: 12px 14px !important;
    border: 1px solid color-mix(in srgb, var(--nd-ink, #15171c) 22%, transparent) !important;
    border-radius: var(--nd-radius, 8px) !important;
    background: color-mix(in srgb, var(--nd-ink, #15171c) 4%, var(--nd-bg, #fff)) !important;
    color: var(--nd-ink, #15171c) !important;
    font: inherit !important;
    box-shadow: none !important;
}
.nd-comp-card {
    display: flex !important;
    flex-direction: column !important;
    gap: 4px !important;
    padding: 18px !important;
    border: 1px solid color-mix(in srgb, var(--nd-ink, #15171c) 10%, transparent) !important;
    border-radius: var(--nd-radius, 8px) !important;
    background: color-mix(in srgb, var(--nd-ink, #15171c) 4%, var(--nd-bg, #fff)) !important;
}
.nd-comp-card strong {
    font-family: var(--nd-font-heading, var(--nd-font-body)) !important;
    font-weight: var(--nd-weight-heading, 700) !important;
}
.nd-comp-card span {
    color: color-mix(in srgb, var(--nd-ink, #15171c) 62%, transparent) !important;
    font-size: 0.9rem !important;
}

/* Elevation — shadow specimens rendered with the real box-shadow. */
.nd-shadows {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 24px 20px;
}
.nd-shadow {
    display: flex;
    flex-direction: column;
}
.nd-shadow-swatch {
    height: 80px;
    border-radius: 6px;
    background: var(--nd-bg, #ffffff);
    border: 1px solid rgba(0, 0, 0, 0.06);
    margin-bottom: 10px;
}
.nd-shadow-name {
    font-family: var(--ds-mono);
    font-size: 12px;
    color: #1d2327;
}
.nd-shadow-spec {
    font-family: var(--ds-mono);
    font-size: 10.5px;
    line-height: 1.4;
    color: #646970;
    margin-top: 2px;
}

/* Animations — described motion patterns. */
.nd-anims {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 12px;
}
.nd-anim {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 14px 16px;
    border: 1px solid #dcdcde;
    border-radius: 4px;
    background: #fff;
}
.nd-anim-name {
    font-weight: 600;
    font-size: 14px;
    color: #1d2327;
}
.nd-anim-desc {
    font-size: 13px;
    line-height: 1.5;
    color: #646970;
}

/* Rendered DESIGN.md body — documentation typography. */
.nd-doc {
    max-width: 78ch;
    color: #50575e;
    font-size: 13px;
    line-height: 1.6;
}
.nd-doc > :first-child {
    margin-top: 0;
}
/* The leading H1 of the document repeats the page title — drop it. */
.nd-doc > h2:first-child {
    display: none;
}
.nd-doc-lead p {
    font-size: 14px;
    line-height: 1.6;
    color: #1d2327;
    margin: 0 0 0.7em;
}
.nd-doc-lead p:last-child {
    margin-bottom: 0;
}
/* Section heads (## in the source). */
.nd-doc h3 {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.3;
    color: #1d2327;
    margin: 24px 0 8px;
    padding-top: 16px;
    border-top: 1px solid #f0f0f1;
}
.nd-doc > h3:first-child,
.nd-doc > h2:first-child + h3 {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
}
/* Sub heads (### in the source). */
.nd-doc h4 {
    font-size: 13px;
    font-weight: 600;
    line-height: 1.3;
    color: #1d2327;
    margin: 16px 0 6px;
}
/* Deep heads. */
.nd-doc h5,
.nd-doc h6 {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #71717a;
    margin: 16px 0 6px;
}
.nd-doc p {
    margin: 0 0 12px;
}
/* Lead paragraph of the first section reads larger. */
.nd-doc > h3:first-child + p,
.nd-doc > h2:first-child + h3 + p {
    font-size: 14px;
    color: #1d2327;
}
.nd-doc strong {
    color: #1d2327;
    font-weight: 600;
}
.nd-doc code {
    font-family: var(--ds-mono);
    font-size: 12px;
    background: #f6f7f7;
    border: 1px solid #dcdcde;
    border-radius: 3px;
    padding: 1px 6px;
    color: #1d2327;
}
.nd-doc ul,
.nd-doc ol {
    margin: 0 0 14px;
    padding-left: 1.4em;
}
.nd-doc li {
    margin: 0 0 6px;
}
/* Do / Don't guidance — colour-coded scannable rows with ✓ / ✕ badges. */
.nd-doc li.nd-doc-do,
.nd-doc li.nd-doc-dont {
    list-style: none;
    position: relative;
    margin-left: -1.4em;
    margin-bottom: 6px;
    padding: 8px 12px 8px 36px;
    border-radius: 4px;
    border: 1px solid #dcdcde;
    color: #1d2327;
}
.nd-doc li.nd-doc-do {
    background: #ecfdf5;
    border-color: #a7f3d0;
}
.nd-doc li.nd-doc-dont {
    background: #fee2e2;
    border-color: #fecaca;
}
.nd-doc li.nd-doc-do::before,
.nd-doc li.nd-doc-dont::before {
    content: "✓";
    position: absolute;
    left: 10px;
    top: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    font-size: 10px;
    font-weight: 700;
    line-height: 1;
    color: #fff;
    background: #15803d;
}
.nd-doc li.nd-doc-dont::before {
    content: "✕";
    background: #b32d2e;
}

/* Grouped Do / Don't columns, regardless of source order. */
.nd-doc-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px 20px;
    margin-top: 4px;
}
@media (max-width: 900px) {
    .nd-doc-split {
        grid-template-columns: 1fr;
    }
}
.nd-doc + .nd-doc-split {
    margin-top: 16px;
}
.nd-doc-col-label {
    display: block;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin: 0 0 8px;
}
.nd-doc-col-label--do {
    color: #15803d;
}
.nd-doc-col-label--dont {
    color: #b32d2e;
}
ul.nd-doc-list {
    list-style: none;
    margin: 0;
    padding: 0;
    max-width: none;
}
.nd-doc-list li.nd-doc-do,
.nd-doc-list li.nd-doc-dont {
    margin-left: 0;
}

/* Collapsible raw source. */
.nd-detail-raw > summary {
    cursor: pointer;
    font-size: 13px;
    color: #646970;
    list-style: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    user-select: none;
}
.nd-detail-raw > summary:hover {
    color: #2271b1;
}
.nd-detail-raw > summary::-webkit-details-marker {
    display: none;
}
.nd-detail-raw > summary::before {
    content: "+";
    font-size: 1rem;
    line-height: 1;
    color: #787c82;
}
.nd-detail-raw[open] > summary {
    margin-bottom: 12px;
}
.nd-detail-raw[open] > summary::before {
    content: "–";
}
.nd-detail-md {
    max-height: 480px;
}

/* Design revision history. */
.nd-history-intro,
.nd-history-empty {
    margin: 0;
    color: #646970;
    font-size: 13px;
    line-height: 1.55;
}
.nd-history-list {
    list-style: none;
    margin: 16px 0 0;
    padding: 0;
    border-top: 1px solid #dcdcde;
}
.nd-history-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid #dcdcde;
}
.nd-history-copy {
    display: flex;
    flex-direction: column;
    min-width: 0;
}
.nd-history-date {
    color: #1d2327;
    font-size: 13px;
    font-weight: 600;
}
.nd-history-meta {
    overflow: hidden;
    color: #646970;
    font-size: 12px;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.nd-history-state {
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 600;
}
.nd-history-state.is-ready {
    background: #e7f5e9;
    color: #1f6f30;
}
.nd-history-state.is-incomplete {
    background: #fcf0d9;
    color: #8a4b08;
}
.nd-history-item form {
    margin: 0;
}
@media (max-width: 700px) {
    .nd-history-item {
        grid-template-columns: 1fr auto;
    }
    .nd-history-copy {
        grid-column: 1 / -1;
    }
}

/* ── Shared bits: raw markdown. ────────────────────────────────────────── */
.novamira-design-md {
    font-family: var(--ds-mono);
    font-size: 12px;
    line-height: 1.6;
    white-space: pre-wrap;
    color: #2c3338;
    background: #f6f7f7;
    border: 1px solid #dcdcde;
    border-radius: 4px;
    padding: 16px;
    max-height: 360px;
    overflow: auto;
    margin-top: 6px;
}


/* ── Import. ─────────────────────────────────────────────────────────────── */
.novamira-design-import {
    background: #fff;
    border: 1px solid #c3c4c7;
    border-radius: 6px;
    padding: 20px 24px;
    margin: 0 0 20px;
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.03);
    max-width: 820px;
}
.novamira-design-import label,
.novamira-design-import p {
    color: #1d2327;
    font-size: 13px;
}
.novamira-design-import textarea {
    font-family: var(--ds-mono);
    font-size: 12.5px;
    line-height: 1.6;
    border-radius: 4px;
}

/* ── Editor view. ────────────────────────────────────────────────────────── */
.novamira-design-edit > h1 a {
    text-decoration: none;
}
.novamira-design-edit-form {
    background: #fff;
    border: 1px solid #c3c4c7;
    border-radius: 6px;
    padding: 20px 24px;
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.03);
}
.novamira-design-edit-form .description {
    color: #646970;
}
.novamira-design-edit-form .CodeMirror {
    border: 1px solid #c3c4c7;
    border-radius: 4px;
}
.novamira-design-edit-grid {
    display: grid;
    grid-template-columns: 1fr 480px;
    gap: 20px;
    align-items: start;
}
/* Preview stays in view beside the editor as you scroll the DESIGN.md. */
.novamira-design-edit-preview {
    position: sticky;
    top: 32px;
    align-self: start;
}
.novamira-design-edit-preview h2 {
    font-size: 18px;
    font-weight: 600;
    color: #1d2327;
    margin: 0 0 12px;
}
.novamira-design-delete-form {
    margin-top: 20px;
}
@media (max-width: 1200px) {
    .novamira-design-edit-grid {
        grid-template-columns: 1fr;
    }
    /* On one column, show the preview above the editor. */
    .novamira-design-edit-preview {
        position: static;
        order: -1;
    }
}

/* ── Token-driven preview — a specimen on a neutral admin mat. The screen
   inside wears the design's tokens; the frame stays WordPress-native.
   Every declaration here and in the components specimen is !important:
   wp-admin loads every active plugin's CSS, and a stray generic selector
   must not leak into the specimen and misrepresent the design. ─────────── */
.nd-preview {
    position: relative !important;
    padding: clamp(20px, 3vw, 36px) !important;
    border-radius: 6px !important;
    background: #f6f7f7 !important;
    border: 1px solid #dcdcde !important;
    overflow: hidden !important;
    container-type: inline-size !important;
}
.nd-preview-screen {
    position: relative !important;
    background: var(--nd-bg, #ffffff) !important;
    color: var(--nd-ink, #15171c) !important;
    font-family: var(--nd-font-body, "Helvetica Neue", Helvetica, Arial, sans-serif) !important;
    border-radius: var(--nd-radius, 10px) !important;
    padding: clamp(22px, 3.4vw, 40px) !important;
    border: 1px solid color-mix(in srgb, var(--nd-ink, #15171c) 12%, transparent) !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 12px 28px -20px rgba(0, 0, 0, 0.25) !important;
}

/* Mini-UI: navigation row */
.nd-preview-nav {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 16px !important;
    padding-bottom: clamp(18px, 2.6vw, 30px) !important;
    margin-bottom: clamp(22px, 3vw, 34px) !important;
    border-bottom: 1px solid color-mix(in srgb, var(--nd-ink, #15171c) 10%, transparent) !important;
}
.nd-preview-brand {
    display: inline-flex !important;
    align-items: center !important;
    gap: 9px !important;
    font-family: var(--nd-font-heading, var(--nd-font-body)) !important;
    font-weight: var(--nd-weight-heading, 700) !important;
    font-size: 1.05rem !important;
    letter-spacing: -0.01em !important;
}
.nd-preview-mark {
    width: 16px !important;
    height: 16px !important;
    border-radius: calc(var(--nd-radius, 8px) * 0.4) !important;
    background: var(--nd-accent, #2271b1) !important;
}
.nd-preview-links {
    display: flex !important;
    gap: 20px !important;
    font-size: 0.82rem !important;
    color: color-mix(in srgb, var(--nd-ink, #15171c) 58%, transparent) !important;
}
.nd-preview-pill {
    font-size: 0.8rem !important;
    font-weight: 600 !important;
    padding: 7px 15px !important;
    border-radius: 999px !important;
    background: color-mix(in srgb, var(--nd-ink, #15171c) 8%, transparent) !important;
    color: var(--nd-ink, #15171c) !important;
}

/* Mini-UI: hero */
.nd-preview-tag {
    display: inline-block !important;
    font-size: 0.72rem !important;
    font-weight: 600 !important;
    letter-spacing: 0.04em !important;
    text-transform: uppercase !important;
    padding: 5px 11px !important;
    border-radius: 999px !important;
    background: color-mix(in srgb, var(--nd-accent, #2271b1) 14%, transparent) !important;
    color: color-mix(in srgb, var(--nd-accent, #2271b1) 85%, var(--nd-ink, #15171c)) !important;
    margin-bottom: 18px !important;
}
.nd-preview-title {
    font-family: var(--nd-font-heading, var(--nd-font-body, "Helvetica Neue", Helvetica, Arial, sans-serif)) !important;
    font-weight: var(--nd-weight-heading, 600) !important;
    font-size: clamp(1.9rem, 4vw, 3rem) !important;
    line-height: 1.04 !important;
    letter-spacing: -0.025em !important;
    margin: 0 0 0.5em !important;
    max-width: 18ch !important;
}
.nd-preview-lede {
    font-size: 1.0625rem !important;
    line-height: 1.6 !important;
    color: color-mix(in srgb, var(--nd-ink, #15171c) 70%, transparent) !important;
    margin: 0 0 26px !important;
    max-width: 52ch !important;
}
.nd-preview-actions {
    display: flex !important;
    align-items: center !important;
    gap: 22px !important;
    flex-wrap: wrap !important;
}
.nd-preview-btn {
    font: inherit !important;
    font-size: 0.9375rem !important;
    font-weight: 600 !important;
    letter-spacing: 0.01em !important;
    border-radius: var(--nd-radius, 8px) !important;
    padding: 12px 22px !important;
}
.nd-preview-btn-primary {
    background: var(--nd-accent, #2271b1) !important;
    color: #fff !important;
    box-shadow: 0 14px 30px -14px color-mix(in srgb, var(--nd-accent, #2271b1) 80%, transparent) !important;
}
.nd-preview-btn-ghost {
    background: transparent !important;
    padding: 12px 4px !important;
    color: var(--nd-ink, #15171c) !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
}
.nd-preview-arrow {
    color: var(--nd-accent, #2271b1) !important;
}

/* Mini-UI: feature tiles */
.nd-preview-grid {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 12px !important;
    margin-top: clamp(24px, 3.4vw, 38px) !important;
}
.nd-preview-tile {
    display: flex !important;
    flex-direction: column !important;
    gap: 3px !important;
    padding: 16px !important;
    border-radius: calc(var(--nd-radius, 8px) * 0.9) !important;
    background: color-mix(in srgb, var(--nd-ink, #15171c) 4%, var(--nd-bg, #fff)) !important;
    border: 1px solid color-mix(in srgb, var(--nd-ink, #15171c) 9%, transparent) !important;
}
.nd-preview-num {
    font-family: var(--nd-font-heading, var(--nd-font-body)) !important;
    font-weight: var(--nd-weight-heading, 700) !important;
    font-size: 0.85rem !important;
    color: var(--nd-accent, #2271b1) !important;
    margin-bottom: 6px !important;
}
.nd-preview-tile strong {
    font-weight: 600 !important;
    font-size: 0.98rem !important;
}
.nd-preview-tile-sub {
    font-size: 0.8rem !important;
    color: color-mix(in srgb, var(--nd-ink, #15171c) 58%, transparent) !important;
}
@container (max-width: 600px) {
    .nd-preview-grid {
        grid-template-columns: 1fr !important;
    }
    .nd-preview-links {
        display: none !important;
    }
}

/* Missing-font note: a small chip overlaid on the preview mat. */
.nd-preview-fontnote {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 2;
    max-width: calc(100% - 16px);
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 2px 8px;
    padding: 4px 10px;
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid #dcdcde;
    border-radius: 4px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    font-size: 11px;
    color: #646970;
}
.nd-preview-fontnote .button-link {
    font-size: 11px;
}

/* Trust advisory on the import page: the file reaches the agent. */
.novamira-design-import-trust {
    max-width: 820px;
    margin: 0 0 20px;
    padding: 10px 14px;
    border: 1px solid #fde68a;
    border-left: 3px solid #f59e0b;
    background: #fffbeb;
    color: #78350f;
    font-size: 13px;
    line-height: 1.5;
}
