.app-create-dialog{box-sizing:border-box;width:min(1100px,calc(100vw - 32px));max-width:none;max-height:calc(100dvh - 40px);margin:auto;padding:0;border:1px solid #465164;border-radius:18px;background:#191e26;color:#e7ecf3;box-shadow:0 24px 90px #0009;overflow:auto;color-scheme:dark}
.app-create-dialog:not([open]){display:none!important}
.app-create-dialog::backdrop{background:rgba(0,0,0,.68);backdrop-filter:blur(3px)}
.app-create-dialog-header{position:sticky;top:0;z-index:5;display:flex;justify-content:space-between;align-items:center;gap:16px;padding:18px 22px;border-bottom:1px solid #354050;background:#191e26}
.app-create-dialog-header h2{margin:0;font-size:19px;line-height:1.4}
.app-create-dialog-header>button{flex:0 0 auto;min-width:34px;min-height:34px;padding:2px 9px;font-size:22px;color:#c5cdda;border:1px solid #465164;border-radius:9px;background:#222a35;cursor:pointer}
.app-create-dialog-body{padding:20px 22px}
.app-create-dialog-body>.leaderboard-config-modal{width:100%;margin:0;padding:0;border:0;box-shadow:none;background:transparent}
.app-create-dialog-body>.nc-editor{margin:0;padding:0;border:0;max-width:none;background:transparent}
.app-create-dialog .nc-editor>h2{display:none}
.app-create-dialog :focus-visible{outline:2px solid #f9cf30;outline-offset:2px}
.leaderboard-config-page:not(:has(> .leaderboard-config-modal)){grid-template-columns:1fr}
.app-create-dialog .strategy-modal-actions{position:sticky;bottom:0;background:#191e26;padding-block:14px;border-top:1px solid #354050}
@media(max-width:600px){.app-create-dialog{width:calc(100vw - 16px);max-height:calc(100dvh - 16px);border-radius:12px}.app-create-dialog-header,.app-create-dialog-body{padding:14px}}
.native-select-replaced{display:none!important}
.native-select-host{min-width:0;width:100%}
.native-select-host[hidden]{display:none!important}
#form-panel .native-select-host .app-select-trigger{height:44px;font:inherit}

.channel-option-label{display:inline-flex;align-items:center;gap:8px;vertical-align:middle}
.channel-option-label img{width:20px;height:20px;object-fit:contain;flex:none;border-radius:4px}
.app-select-value{display:inline-flex;align-items:center;margin-right:12px}

.channel-type-field{display:grid;gap:8px;color:#b9c3d2}
.channel-type-radios{display:flex;align-items:center;gap:24px;flex-wrap:wrap;min-height:38px}
.channel-type-radios label{display:inline-flex!important;align-items:center;gap:8px!important;margin:0;cursor:pointer}
.channel-type-radios input[type=radio]{width:16px!important;height:16px!important;min-height:0;margin:0;padding:0;accent-color:#f9cf30}
.channel-type-radios label:has(input:disabled){opacity:.55;cursor:default}
.app-create-dialog:has(.nc-editor){height:min(560px,calc(100dvh - 40px));display:grid;grid-template-rows:auto minmax(0,1fr);overflow:hidden}
.app-create-dialog:has(.nc-editor)>.app-create-dialog-body{overflow-y:auto;scrollbar-gutter:stable}

.app-create-dialog .nc-form-grid>label:first-of-type,.app-create-dialog .nc-form-grid>.channel-type-field{grid-column:1/-1}
/* Notification forms share the same spacing, controls and actions as rule dialogs. */
.app-create-dialog .nc-editor{display:flex;flex-direction:column;min-height:100%;font-size:14px}
.app-create-dialog .nc-form-grid{margin:0;gap:16px;align-items:start}
.app-create-dialog .nc-form-grid>label,.app-create-dialog .channel-type-field{font-size:14px;line-height:20px;color:#b9c3d2;gap:8px}
.app-create-dialog .nc-form-grid input:not([type=checkbox]):not([type=radio]),.app-create-dialog .nc-form-grid .app-select-trigger{box-sizing:border-box;width:100%;height:44px;min-height:44px;padding:10px 12px;border:1px solid #3a4658;border-radius:9px;background:#10161e;color:#e7ecf3;font:inherit}
.app-create-dialog .channel-type-radios{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}
.app-create-dialog .channel-type-radios label{padding:12px;border:1px solid #3a4658;border-radius:10px;background:#10161e;min-height:48px;transition:border-color .15s,background .15s}
.app-create-dialog .channel-type-radios label:has(input:checked){border-color:#c9a327;background:#f9cf3012;color:#ffda53}
.app-create-dialog .nc-form-grid>.nc-check{grid-column:1/-1;min-height:20px}
.app-create-dialog .nc-editor input[type=checkbox]{accent-color:#f9cf30}
.app-create-dialog .nc-editor footer{margin-top:auto;padding-top:20px;display:flex;gap:10px;border-top:1px solid #354050}
.app-create-dialog .nc-editor .nc-form-grid{padding-bottom:20px}
.app-create-dialog .nc-editor footer button{min-height:40px;padding:9px 16px;border:1px solid #3a4658;border-radius:9px;background:#222a35;color:#e7ecf3;font:inherit;cursor:pointer}
.app-create-dialog .nc-editor footer button:first-child{border-color:#f9cf30;background:#f9cf30;color:#14191f;font-weight:700}
.app-create-dialog .nc-editor footer button:disabled{opacity:.5;cursor:default}
@media(max-width:600px){.app-create-dialog .channel-type-radios{grid-template-columns:1fr}.app-create-dialog .nc-form-grid{grid-template-columns:minmax(0,1fr)}}

.snapshot-studio-delta{display:inline-flex;align-items:center;gap:6px;white-space:nowrap;padding:6px 10px;border:1px solid #3a4658;border-radius:9px;color:#b9c3d2;font-size:13px}.snapshot-studio-delta b{color:#ffd633;font-variant-numeric:tabular-nums}

/* Form layout rules must not override conditional field visibility. */
.nc-rule-dialog [hidden]{display:none!important}

.nc-channels .nc-actions button[data-action=copy]{--action-color:#8cbeff;--action-background:rgba(85,155,245,.08);--action-border:rgba(85,155,245,.2)}
