/* UNIBEX MKT Admin — app shell polish */

:root {
    --bg: #e8f3f9;
    --bg-deep: #d2e6f2;
    --card: rgba(255, 255, 255, .92);
    --ink: #123552;
    --muted: #5b87a8;
    --line: rgba(120, 180, 230, .35);
    --brand: #2a78ff;
    --brand-2: #202088;
    --brand-soft: #5ec8ff;
    --accent: #d4a017;
    --danger: #b42318;
    --ok: #067647;
    --shadow: 0 1px 0 rgba(255, 255, 255, .85) inset, 0 14px 36px rgba(40, 90, 140, .1), 0 4px 12px rgba(40, 90, 140, .05);
    --radius: 18px;
    --font: "Outfit", "Noto Sans TC", sans-serif;
    --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
    --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
}

* { box-sizing: border-box; }

body:not(.is-login) {
    margin: 0;
    min-height: 100vh;
    font-family: var(--font);
    color: var(--ink);
    background-color: #dceef8;
    background-image:
        radial-gradient(ellipse 80% 50% at 10% 0%, rgba(120, 190, 255, .35), transparent 55%),
        radial-gradient(ellipse 70% 45% at 95% 10%, rgba(180, 220, 255, .45), transparent 50%),
        linear-gradient(165deg, #eaf6ff, #cfe6f7 55%, #b9daf0);
    background-attachment: fixed;
}

/* watermark soft layer — readable, not noisy */
body:not(.is-login)::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background-image: url("../images/logo-tile.png?v=4");
    background-repeat: repeat;
    background-size: auto;
    opacity: .045;
}

body:not(.is-login)::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background-image:
        linear-gradient(rgba(40, 110, 180, .045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(40, 110, 180, .045) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: radial-gradient(ellipse at 50% 30%, #000 15%, transparent 75%);
}

a {
    color: var(--brand);
    text-decoration: none;
    font-weight: 600;
    transition: color .18s ease;
}
a:hover { color: var(--brand-2); }

.wrap {
    width: 94%;
    max-width: none;
    margin: 0 auto;
    padding: 22px 0 64px;
    position: relative;
    z-index: 1;
    animation: adminRise .55s var(--ease-out) both;
}

@keyframes adminRise {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: none; }
}

/* —— Top bar (light dock + brand-blue active) —— */
.shell-bar {
    --nav-dock: rgba(255, 255, 255, .92);
    --nav-active: #2a78ff;
    --nav-active-soft: #5ec8ff;
    --nav-ink: #123552;
    --nav-muted: #6f93ad;
    position: relative;
    z-index: 100;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 28px;
    flex-wrap: nowrap;
    padding: 8px 10px 8px 14px;
    border-radius: 18px;
    background: rgba(255, 255, 255, .82);
    border: 1px solid rgba(120, 180, 230, .28);
    box-shadow:
        0 1px 0 rgba(255, 255, 255, .9) inset,
        0 10px 28px rgba(40, 90, 140, .08);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 800;
    font-size: 1.15rem;
    letter-spacing: .02em;
    color: var(--ink);
    flex: 0 0 auto;
}

.brand-logo {
    display: block;
    height: 36px;
    width: auto;
    max-width: 148px;
    object-fit: contain;
}

.brand-text {
    display: flex;
    flex-direction: column;
    gap: 1px;
    line-height: 1.15;
}

.brand-text span {
    font-size: .68rem;
    font-weight: 700;
    color: var(--muted);
    letter-spacing: .16em;
    text-transform: uppercase;
}

.nav {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    gap: 4px;
    margin-left: auto;
    min-width: 0;
    max-width: 100%;
    overflow: visible;
}

.nav-dock {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: flex-end;
    gap: 2px;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
    font-family: "Outfit", "Noto Sans TC", sans-serif;
    flex: 1 1 auto;
    min-width: 0;
    overflow-x: auto;
    overflow-y: visible;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
}

.nav-dock__item {
    position: relative;
    display: inline-flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 42px;
    padding: 8px 12px;
    border-radius: 12px;
    color: var(--nav-muted);
    text-decoration: none;
    font-weight: 700;
    flex: 0 0 auto;
    transition:
        color .2s ease,
        background .2s var(--ease-out),
        transform .16s var(--ease-out);
}

.nav-dock__icon {
    position: relative;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px !important;
    height: 18px !important;
    max-width: 18px;
    max-height: 18px;
    flex: 0 0 18px;
    overflow: hidden;
    line-height: 0;
    transition: color .2s ease, transform .2s var(--ease-out);
}

.nav-dock__icon svg {
    width: 18px !important;
    height: 18px !important;
    max-width: 18px;
    max-height: 18px;
    display: block;
    flex: 0 0 auto;
}

.nav-dock__text {
    position: static;
    z-index: 2;
    transform: none;
    padding: 0;
    border-radius: 0;
    background: transparent;
    color: inherit;
    font-size: .9rem;
    font-weight: 700;
    letter-spacing: .01em;
    line-height: 1.2;
    white-space: nowrap;
    opacity: 1;
    pointer-events: auto;
    box-shadow: none;
}

.nav-dock__fx {
    display: none;
}

@media (hover: hover) and (pointer: fine) {
    .nav-dock__item:hover {
        color: var(--nav-active);
        background: rgba(42, 120, 255, .08);
    }
    .nav-dock__item:hover .nav-dock__icon {
        transform: translateY(-1px);
    }
}

.nav-dock__item.is-active {
    color: var(--brand-2);
    background: linear-gradient(135deg, rgba(94, 200, 255, .22), rgba(42, 120, 255, .14));
    box-shadow: 0 0 0 1px rgba(42, 120, 255, .16);
}

.nav-dock__item.is-active .nav-dock__icon {
    color: var(--nav-active);
    transform: none;
    filter: none;
}

.nav-account {
    position: relative;
    z-index: 120;
    flex: 0 0 auto;
    margin-left: 6px;
    overflow: visible;
}

.nav-account__toggle {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    min-height: 42px;
    padding: 4px 10px 4px 4px;
    border: 0;
    border-radius: 12px;
    background: transparent;
    color: var(--nav-ink);
    font: inherit;
    font-family: "Outfit", "Noto Sans TC", sans-serif;
    font-weight: 700;
    cursor: pointer;
    box-shadow: none;
    transition: background .18s ease, transform .16s var(--ease-out);
}

.nav-account.is-open .nav-account__toggle,
.nav-account.is-active .nav-account__toggle {
    background: rgba(42, 120, 255, .1);
}

@media (hover: hover) and (pointer: fine) {
    .nav-account__toggle:hover {
        background: rgba(42, 120, 255, .08);
    }
}

.nav-account__avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 999px;
    background: linear-gradient(145deg, #5ec8ff, #2a78ff 55%, #202088);
    color: #fff;
    font-size: .76rem;
    font-weight: 800;
    letter-spacing: .02em;
    text-transform: uppercase;
    flex: 0 0 auto;
}

.nav-account__label {
    display: grid;
    gap: 1px;
    text-align: left;
    line-height: 1.15;
}

.nav-account__name {
    font-size: .9rem;
    color: var(--nav-ink);
}

.nav-account__role {
    font-size: .68rem;
    font-weight: 600;
    color: var(--nav-muted);
}

.nav-account__caret {
    width: 0;
    height: 0;
    margin-left: 2px;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 5px solid currentColor;
    opacity: .5;
    color: var(--nav-muted);
    transition: transform .18s var(--ease-out);
}

.nav-account.is-open .nav-account__caret {
    transform: rotate(180deg);
}

.nav-account__menu {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    min-width: 220px;
    padding: 8px;
    border-radius: 14px;
    background: #fff;
    border: 1px solid rgba(120, 180, 230, .35);
    box-shadow:
        0 18px 40px rgba(18, 53, 82, .14),
        0 4px 12px rgba(18, 53, 82, .06);
    z-index: 120;
    font-family: "Outfit", "Noto Sans TC", sans-serif;
}

.nav-account__meta {
    display: grid;
    gap: 2px;
    padding: 10px 12px 12px;
    margin-bottom: 4px;
    border-bottom: 1px solid rgba(120, 180, 230, .22);
}

.nav-account__meta strong {
    font-size: .95rem;
    color: var(--nav-ink);
}

.nav-account__meta span {
    font-size: .78rem;
    color: var(--nav-muted);
    font-weight: 600;
}

.nav-account__menu a,
.nav-account__menu button {
    display: block;
    width: 100%;
    padding: 11px 12px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--nav-ink);
    font: inherit;
    font-weight: 700;
    font-size: .92rem;
    text-align: left;
    cursor: pointer;
    text-decoration: none;
}

@media (hover: hover) and (pointer: fine) {
    .nav-account__menu a:hover,
    .nav-account__menu button:hover {
        background: rgba(42, 120, 255, .08);
        color: var(--nav-active);
    }
}

.nav-account__menu a.is-active {
    background: rgba(42, 120, 255, .12);
    color: var(--brand-2);
}

.nav-account__menu form {
    margin: 0;
}

.nav-account__menu button[type="submit"] {
    color: #9a3412;
}

@media (hover: hover) and (pointer: fine) {
    .nav-account__menu button[type="submit"]:hover {
        background: rgba(180, 35, 24, .08);
        color: var(--danger);
    }
}

@media (max-width: 980px) {
    .shell-bar {
        gap: 10px;
        padding: 8px;
    }
    .nav-dock__item {
        padding: 8px 10px;
        gap: 6px;
    }
    .nav-dock__text {
        font-size: .82rem;
    }
    .nav-account__label {
        display: none;
    }
    .nav-account__toggle {
        padding-right: 8px;
    }
}

@media (max-width: 720px) {
    .brand-text {
        display: none;
    }
    .nav-dock__text {
        display: none;
    }
    .nav-dock__item {
        min-width: 42px;
        padding: 8px;
    }
}

/* —— Page heading —— */
.page-head {
    margin: 0 0 22px;
    animation: adminEnter .5s var(--ease-out) .06s both;
}

.page-head--row {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.page-head--edit {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

body.is-campaign-edit {
    scroll-padding-top: 5.5rem;
}

body.is-campaign-edit .wrap {
    animation: none;
}

body.is-campaign-edit [id^="section-"] {
    scroll-margin-top: 5.5rem;
}

body.is-campaign-edit .section-jump {
    position: sticky;
    top: 0;
    z-index: 40;
    margin: 0 0 18px;
    padding: 10px 0 12px;
    justify-content: flex-start;
    background:
        linear-gradient(180deg, rgba(220, 238, 248, .98) 0%, rgba(220, 238, 248, .94) 78%, rgba(220, 238, 248, .72));
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

@media (prefers-reduced-transparency: reduce) {
    body.is-campaign-edit .section-jump {
        background: #dceef8;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }
}

.page-head__title {
    flex: 0 1 auto;
    min-width: 140px;
}

.section-jump {
    display: flex;
    flex: 1 1 auto;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
}

.section-jump .btn {
    padding: 8px 12px;
    font-size: .9rem;
    box-shadow: none;
}

.page-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
}

#section-basic,
#section-brand,
#section-footer,
#section-legal,
#section-mail {
    scroll-margin-top: 24px;
}

body.is-campaign-edit #section-basic,
body.is-campaign-edit #section-brand,
body.is-campaign-edit #section-footer,
body.is-campaign-edit #section-legal,
body.is-campaign-edit #section-mail {
    scroll-margin-top: 5.5rem;
}

.page-head h1 {
    margin: 0;
    font-size: clamp(1.7rem, 3vw, 2.1rem);
    font-weight: 800;
    letter-spacing: -.02em;
    color: var(--ink);
}

.page-head .muted,
.wrap > .muted {
    margin: 8px 0 0;
    color: var(--muted);
    font-weight: 500;
}

.wrap > h1 {
    margin: 0 0 6px;
    font-size: clamp(1.7rem, 3vw, 2.1rem);
    font-weight: 800;
    letter-spacing: -.02em;
    animation: adminEnter .5s var(--ease-out) .06s both;
}

.wrap > h1 + .muted {
    margin-top: 0;
    margin-bottom: 22px;
    animation: adminEnter .5s var(--ease-out) .12s both;
}

@keyframes adminEnter {
    from { opacity: 0; transform: translateY(14px) scale(.985); }
    to { opacity: 1; transform: none; }
}

/* —— Cards —— */
.card {
    background: var(--card);
    border: 1px solid rgba(120, 180, 230, .32);
    border-radius: var(--radius);
    padding: 20px 20px 16px;
    margin-bottom: 18px;
    box-shadow: var(--shadow);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition:
        transform .22s var(--ease-out),
        box-shadow .22s ease,
        border-color .22s ease;
    animation: adminEnter .55s var(--ease-out) both;
}

.card:nth-of-type(1) { animation-delay: .14s; }
.card:nth-of-type(2) { animation-delay: .22s; }
.card:nth-of-type(3) { animation-delay: .3s; }
.card:nth-of-type(4) { animation-delay: .38s; }

@media (hover: hover) and (pointer: fine) {
    .card:hover {
        transform: translateY(-2px);
        border-color: rgba(42, 120, 255, .35);
        box-shadow:
            0 1px 0 rgba(255, 255, 255, .9) inset,
            0 20px 44px rgba(40, 90, 140, .14),
            0 0 0 1px rgba(94, 200, 255, .12);
    }
}

.card > .top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    background: transparent;
    border: 0;
    box-shadow: none;
    backdrop-filter: none;
    padding: 0;
    margin: 0 0 14px;
    border-radius: 0;
}

.card > .top h2 {
    margin: 0;
    font-size: 1.12rem;
    font-weight: 800;
    letter-spacing: .02em;
}

/* —— Tables —— */
.table-scroll {
    overflow-x: auto;
    margin: 0 -4px;
    padding: 0 4px;
}

table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

th, td {
    text-align: left;
    padding: 13px 12px;
    border-bottom: 1px solid var(--line);
    font-size: .94rem;
    vertical-align: middle;
}

th {
    color: var(--muted);
    font-weight: 700;
    font-size: .76rem;
    letter-spacing: .08em;
    text-transform: uppercase;
    background: rgba(234, 246, 255, .55);
}

th:first-child { border-radius: 12px 0 0 12px; }
th:last-child { border-radius: 0 12px 12px 0; }

tbody tr {
    transition: background .18s ease, transform .16s var(--ease-out);
    animation: adminRowIn .45s var(--ease-out) both;
}

tbody tr:nth-child(1) { animation-delay: .18s; }
tbody tr:nth-child(2) { animation-delay: .24s; }
tbody tr:nth-child(3) { animation-delay: .3s; }
tbody tr:nth-child(4) { animation-delay: .36s; }
tbody tr:nth-child(5) { animation-delay: .42s; }
tbody tr:nth-child(n+6) { animation-delay: .48s; }

@keyframes adminRowIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: none; }
}

@media (hover: hover) and (pointer: fine) {
    tbody tr:hover {
        background: rgba(94, 200, 255, .1);
    }
}

tbody tr:last-child td {
    border-bottom: 0;
}

td a {
    display: inline-flex;
    align-items: center;
    padding: 6px 10px;
    border-radius: 9px;
    background: rgba(42, 120, 255, .08);
    transition: background .18s ease, transform .16s var(--ease-out);
}

@media (hover: hover) and (pointer: fine) {
    td a:hover {
        background: rgba(42, 120, 255, .16);
        transform: translateY(-1px);
    }
}

td a:active { transform: scale(.97); }

/* —— Buttons —— */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: linear-gradient(135deg, var(--brand-soft), var(--brand) 50%, var(--brand-2));
    color: #fff !important;
    border: 0;
    border-radius: 12px;
    padding: 10px 16px;
    cursor: pointer;
    font: inherit;
    font-weight: 800;
    letter-spacing: .02em;
    box-shadow: 0 8px 18px rgba(42, 120, 255, .28);
    transition:
        transform .16s var(--ease-out),
        box-shadow .2s ease,
        filter .18s ease;
}

@media (hover: hover) and (pointer: fine) {
    .btn:hover {
        transform: translateY(-1px);
        filter: brightness(1.05);
        box-shadow: 0 12px 26px rgba(42, 120, 255, .34);
    }
}

.btn:active {
    transform: scale(.97);
    filter: brightness(.98);
}

.btn.secondary {
    background: rgba(255, 255, 255, .92);
    color: var(--brand-2) !important;
    border: 1px solid rgba(42, 120, 255, .28);
    box-shadow: 0 4px 12px rgba(40, 90, 140, .08);
}

.btn.danger {
    background: linear-gradient(135deg, #f04438, var(--danger));
    box-shadow: 0 8px 18px rgba(180, 35, 24, .22);
}

.list-filter {
    display: grid;
    grid-template-columns: minmax(180px, 1.4fr) minmax(120px, .8fr) auto;
    gap: 12px;
    align-items: end;
    margin: 0 0 16px;
}

.list-filter--campaigns {
    grid-template-columns: minmax(180px, 1.4fr) minmax(120px, .7fr) minmax(160px, 1fr) auto;
}

.list-filter label {
    margin-top: 0;
}

.list-filter__actions {
    display: flex;
    gap: 8px;
    align-items: end;
    flex-wrap: wrap;
}

@media (max-width: 860px) {
    .list-filter,
    .list-filter--campaigns {
        grid-template-columns: 1fr;
    }
}

.row-ops {
    width: 1%;
    white-space: nowrap;
    text-align: right;
    vertical-align: middle;
}

.row-ops > a,
.row-ops > form {
    display: inline;
    margin: 0;
    vertical-align: baseline;
}

.row-ops > a + form,
.row-ops > form + form,
.row-ops > a + a {
    margin-left: 14px;
}

.row-ops form + form {
    margin-left: 14px;
}

.row-ops .link-action {
    display: inline;
    margin: 0;
    padding: 0;
    border: 0;
    background: none;
    box-shadow: none;
    color: var(--brand-2);
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    letter-spacing: inherit;
}

.row-ops .link-action.is-danger {
    color: var(--danger);
}

@media (hover: hover) and (pointer: fine) {
    .row-ops .link-action:hover {
        text-decoration: underline;
        filter: none;
        transform: none;
    }
}

tr.is-row-inactive td {
    opacity: .72;
}

.check-inline {
    display: flex !important;
    align-items: center;
    gap: 8px;
    margin: 0 !important;
    font-weight: 600 !important;
    color: var(--ink) !important;
    cursor: pointer;
}

.check-inline input {
    width: auto;
    margin: 0;
}

/* —— Forms —— */
label {
    display: block;
    font-size: .86rem;
    margin: 12px 0 6px;
    color: var(--muted);
    font-weight: 700;
}

input, select, textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1.5px solid rgba(120, 180, 230, .55);
    border-radius: 12px;
    font: inherit;
    background: rgba(255, 255, 255, .95);
    color: var(--ink);
    transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: #3aa0ff;
    box-shadow: 0 0 0 4px rgba(58, 160, 255, .14);
    background: #fff;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 14px;
}

.flash {
    background: #e8f7ef;
    border: 1px solid #abefc6;
    color: var(--ok);
    padding: 12px 14px;
    border-radius: 12px;
    margin-bottom: 16px;
    font-weight: 700;
    animation: adminEnter .45s var(--ease-out) both;
}

.error {
    background: #fef3f2;
    border: 1px solid #fecdca;
    color: var(--danger);
    padding: 12px 14px;
    border-radius: 12px;
    margin-bottom: 16px;
    animation: adminEnter .45s var(--ease-out) both;
}

.muted { color: var(--muted); }

.pill,
.status-pill {
    display: inline-flex;
    align-items: center;
    padding: 5px 10px;
    border-radius: 10px;
    background: rgba(42, 120, 255, .1);
    font-size: .78rem;
    font-weight: 800;
    color: var(--brand-2);
    letter-spacing: .02em;
}

.status-pill.is-active {
    background: rgba(6, 118, 71, .12);
    color: var(--ok);
}

.status-pill.is-draft,
.status-pill.is-inactive {
    background: rgba(91, 135, 168, .14);
    color: var(--muted);
}

code {
    font-family: ui-monospace, "Cascadia Code", Consolas, monospace;
    font-size: .86em;
    background: rgba(234, 246, 255, .9);
    color: #1a4f7a;
    padding: 3px 7px;
    border-radius: 8px;
    border: 1px solid rgba(120, 180, 230, .35);
}

.color-field__row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.color-field__swatch {
    width: 48px;
    height: 44px;
    padding: 0;
    border: 1.5px solid rgba(120, 180, 230, .55);
    border-radius: 12px;
    background: transparent;
    cursor: pointer;
    flex: 0 0 auto;
    overflow: hidden;
    transition: transform .16s var(--ease-out), border-color .2s ease, box-shadow .2s ease;
}

.color-field__swatch::-webkit-color-swatch-wrapper {
    padding: 3px;
}

.color-field__swatch::-webkit-color-swatch {
    border: 0;
    border-radius: 8px;
}

.color-field__swatch::-moz-color-swatch {
    border: 0;
    border-radius: 8px;
}

@media (hover: hover) and (pointer: fine) {
    .color-field__swatch:hover {
        transform: translateY(-1px);
        border-color: rgba(42, 120, 255, .45);
        box-shadow: 0 0 0 4px rgba(58, 160, 255, .12);
    }
}

.color-field__swatch:active {
    transform: scale(.97);
}

.color-field__hex {
    flex: 1 1 auto;
    min-width: 0;
    font-family: ui-monospace, "Cascadia Code", Consolas, monospace;
    letter-spacing: .02em;
}

.logo-field__body {
    display: grid;
    grid-template-columns: minmax(220px, 320px) minmax(180px, 1fr);
    gap: 14px;
    align-items: stretch;
}

.logo-field__preview {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 96px;
    padding: 12px;
    border-radius: 14px;
    border: 1.5px solid rgba(120, 180, 230, .45);
    background:
        linear-gradient(45deg, rgba(180, 210, 230, .25) 25%, transparent 25%),
        linear-gradient(-45deg, rgba(180, 210, 230, .25) 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, rgba(180, 210, 230, .25) 75%),
        linear-gradient(-45deg, transparent 75%, rgba(180, 210, 230, .25) 75%),
        #fff;
    background-size: 16px 16px;
    background-position: 0 0, 0 8px, 8px -8px, -8px 0;
}

.logo-field__preview img {
    display: block;
    max-width: 100%;
    max-height: 88px;
    width: auto;
    height: auto;
    object-fit: contain;
}

.logo-field__controls {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
    justify-content: center;
    max-width: 420px;
}

.logo-field__row {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.logo-field__row input[type="text"] {
    flex: 1 1 auto;
    min-width: 0;
    max-width: 280px;
}

.logo-field__file-input {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.logo-field__pick {
    flex: 0 0 auto;
    margin: 0;
    cursor: pointer;
    white-space: nowrap;
}

.logo-field__status {
    margin: 0;
    font-size: .86rem;
    font-weight: 600;
    color: var(--ink);
}

.logo-field__hint {
    margin: 0;
    font-size: .82rem;
}

.grid > .logo-field-span {
    grid-column: 1 / -1;
}

.nav-field__intro {
    margin: 0 0 14px;
}

.nav-items {
    display: grid;
    gap: 12px;
    margin-top: 16px;
}

.nav-item-row {
    border: 1.5px solid rgba(120, 180, 230, .45);
    border-radius: 14px;
    padding: 12px 14px;
    background: rgba(248, 252, 255, .9);
}

.nav-item-row__meta {
    display: flex;
    gap: 8px;
    align-items: center;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.nav-item-row__key {
    font-family: Outfit, sans-serif;
    font-weight: 700;
    font-size: .82rem;
    letter-spacing: .04em;
    color: #1f6f8b;
}

.nav-item-row__audience {
    font-size: .78rem;
    font-weight: 600;
    color: #5b7a88;
    background: rgba(31, 111, 139, .08);
    border-radius: 999px;
    padding: 2px 10px;
}

.nav-item-row__preview {
    font-size: .78rem;
    font-weight: 700;
    color: #fff;
    background: #1f6f8b;
    border-radius: 999px;
    padding: 3px 10px;
    text-decoration: none;
    white-space: nowrap;
}

.nav-item-row__preview:hover {
    filter: brightness(1.08);
}

.nav-item-row__url {
    flex: 1 1 220px;
    min-width: 0;
    font-size: .78rem;
    font-weight: 600;
    color: #1f6f8b;
    text-decoration: underline;
    text-underline-offset: 2px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.nav-item-row__url.is-muted {
    color: #7a93a0;
    text-decoration: none;
    font-weight: 500;
}

.nav-item-row__fields {
    display: grid;
    grid-template-columns: 72px 72px 1.1fr 1.4fr auto auto;
    gap: 10px;
    align-items: end;
}

.nav-item-row__subtitle {
    min-width: 0;
}

.nav-item-row__url-field {
    grid-column: 1 / -1;
}

.nav-item-row__check {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 0;
    font-size: .86rem;
    font-weight: 600;
    white-space: nowrap;
    padding-bottom: 8px;
}

.nav-item-row__check input {
    width: auto;
    margin: 0;
}

@media (max-width: 960px) {
    .nav-item-row__fields {
        grid-template-columns: 1fr 1fr;
    }

    .nav-item-row__subtitle,
    .nav-item-row__url-field {
        grid-column: 1 / -1;
    }
}

.rich-editors {
    display: grid;
    gap: 18px;
    margin: 8px 0 6px;
}

.rich-field__hint {
    margin: 0 0 8px;
    font-size: .86rem;
}

.rich-field .tox-tinymce {
    border-radius: 14px !important;
    border: 1.5px solid rgba(120, 180, 230, .55) !important;
    overflow: hidden;
    box-shadow: none !important;
}

.rich-field .tox .tox-toolbar,
.rich-field .tox .tox-toolbar__overflow,
.rich-field .tox .tox-toolbar__primary {
    background: rgba(234, 246, 255, .75) !important;
}

.rich-field .tox .tox-edit-area__iframe {
    background: #fff !important;
}

@media (max-width: 720px) {
    .logo-field__body {
        grid-template-columns: 1fr;
    }

    .logo-field__row {
        flex-wrap: wrap;
    }

    .logo-field__row input[type="text"] {
        max-width: none;
        width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .wrap,
    .card,
    .page-head,
    .wrap > h1,
    .wrap > h1 + .muted,
    .flash,
    .error,
    tbody tr {
        animation: none !important;
    }
    .btn,
    .nav-dock__item,
    .nav-dock__icon,
    .nav-dock__text,
    .nav-account__toggle,
    .card,
    td a {
        transition: none !important;
    }
}

.survey-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 6px;
    font-weight: 500;
}

.survey-toggle input {
    width: auto;
    margin: 0;
}

.homepage-fields__subhead {
    margin: 18px 0 10px;
    font-size: 1rem;
    font-weight: 700;
    color: #1d4f5c;
}

.homepage-fields__subhead:first-of-type {
    margin-top: 4px;
}

.homepage-fields__group {
    margin: 0 0 14px;
    padding: 12px 14px;
    border: 1px solid #d5e8ed;
    border-radius: 12px;
    background: #f7fbfc;
}

.homepage-fields__row {
    display: flex !important;
    align-items: center !important;
    flex-wrap: nowrap !important;
    gap: 10px !important;
    margin: 0 0 8px !important;
}

.homepage-fields__row-label {
    display: inline !important;
    margin: 0 !important;
    width: auto !important;
    font-size: .86rem;
    font-weight: 700;
    color: var(--muted);
    white-space: nowrap;
}

.homepage-fields__switch {
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    margin: 0 !important;
    width: auto !important;
    font-weight: 500;
    white-space: nowrap;
    cursor: pointer;
}

.homepage-fields__switch input[type="checkbox"] {
    width: auto !important;
    margin: 0 !important;
    flex: none !important;
}

.homepage-showcase-pick {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
}

.homepage-showcase-pick__hint {
    text-align: center;
}

.homepage-showcase-pick__item {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 0 1 200px;
    max-width: 240px;
    margin: 0;
    padding: 8px 10px;
    border: 1px solid #cfe3e8;
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
    font-weight: 500;
}

.homepage-showcase-pick__item:has(input:checked) {
    border-color: #3d9aa8;
    box-shadow: 0 0 0 2px #3d9aa833;
}

.homepage-showcase-pick__item input {
    width: auto;
    margin: 0;
    flex: none;
}

.homepage-showcase-pick__item input:disabled {
    opacity: .45;
    cursor: not-allowed;
}

.homepage-showcase-pick__thumb {
    flex: none;
    width: 48px;
    height: 48px;
    border-radius: 8px;
    background: #eef6f8;
    overflow: hidden;
    display: grid;
    place-items: center;
}

.homepage-showcase-pick__thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.homepage-showcase-pick__puzzle {
    display: block;
    width: 100%;
    height: 100%;
    background-size: 300% 300%;
    background-repeat: no-repeat;
    background-color: #eef6f8;
}

.homepage-showcase-pick__meta {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.homepage-showcase-pick__meta strong {
    font-size: .9rem;
    line-height: 1.25;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.homepage-showcase-pick__meta small {
    color: #6a858e;
    font-size: .75rem;
}
