/* Services share the panel's white surfaces, fine borders and blue actions. */
body[data-dn-ui] [data-page-panel] > .dn57-service-window { padding: 0 !important; border: 0 !important; background: transparent !important; }
.dn57-service-window { width: min(1120px, 100%); max-height: 92dvh; overflow: auto; background: #fff; border: 1px solid #e5e7eb; border-radius: 14px; }
.dn57-window-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 22px; border-bottom: 1px solid #e5e7eb; }
.dn57-window-head h3 { margin: 0; font-size: 16px; }
.dn57-window-head button { border: 0; background: transparent; padding: 8px; }
body[data-dn-ui] [data-page-panel] .dn57-window-head { display: none; }
.dn57-services { padding: 24px; display: grid; gap: 22px; color: #1f2937; }
body[data-dn-ui] [data-page-panel] .dn57-services { padding: 0; }
.dn57-services h2, .dn57-services h3, .dn57-services p { margin: 0; }
.dn57-services h2 { font-size: 23px; font-weight: 700; margin: 4px 0 6px; line-height: 1.4; }
.dn57-intro { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.dn57-intro p, .dn57-card-head p { color: #737b88; font-size: 12px; line-height: 1.7; }
.dn57-eyebrow { color: #7c8492; font-size: 10px; font-weight: 700; letter-spacing: 1.4px; }
.dn57-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.dn57-stats-two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.dn57-stat { border: 1px solid #e4e7ed; border-radius: 12px; background: #fff; padding: 18px; display: flex; align-items: center; gap: 13px; min-width: 0; }
.dn57-stat-icon, .dn57-section-icon { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto; width: 36px; height: 36px; border-radius: 10px; background: #eff4ff; color: #2563eb; }
.dn57-stat > div { display: flex; flex-direction: column; min-width: 0; }
.dn57-stat > div > span { font-size: 11px; color: #78808d; }
.dn57-stat strong { font-size: 26px; line-height: 1.4; font-variant-numeric: tabular-nums; }
.dn57-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; align-items: start; }
.dn57-main-grid { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(270px, 1fr); gap: 20px; align-items: start; }
.dn57-stack { display: grid; gap: 18px; min-width: 0; }
.dn57-card { border: 1px solid #e4e7ed; border-radius: 12px; background: #fff; overflow: hidden; min-width: 0; }
.dn57-card-head { padding: 18px 20px; border-bottom: 1px solid #eceef2; display: flex; align-items: center; gap: 12px; }
.dn57-card-head > div { flex: 1; min-width: 0; }
.dn57-card-head h3, .dn57-card-body h3 { font-size: 14px; font-weight: 650; }
.dn57-card-head p { margin-top: 3px; font-size: 11px; }
.dn57-card-body { padding: 20px; display: grid; gap: 18px; }
.dn57-form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 16px; }
.dn57-field { display: grid; gap: 7px; align-content: start; min-width: 0; }
.dn57-field > span, .dn57-project-field legend { color: #374151; font-weight: 600; font-size: 12px; }
.dn57-field input, .dn57-field select, .dn57-field textarea { width: 100%; min-width: 0; padding: 10px 12px; }
.dn57-field textarea { resize: vertical; min-height: 88px; }
.dn57-field small, .dn57-help { color: #858c97; font-size: 11px; line-height: 1.8; overflow-wrap: anywhere; }
.dn57-toggle-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 0; border-bottom: 1px solid #eceef2; cursor: pointer; }
.dn57-toggle-row strong { color: #303947; font-size: 13px; font-weight: 600; display: block; }
.dn57-toggle-row small { color: #858c97; font-size: 11px; display: block; margin-top: 3px; }
body[data-dn-ui] input.dn57-switch { appearance: none; -webkit-appearance: none; width: 40px; height: 24px; min-height: 24px; border: 1px solid #d1d5db; border-radius: 99px; background: #d8dde5; position: relative; transition: background .15s; cursor: pointer; }
body[data-dn-ui] input.dn57-switch::after { content: ''; position: absolute; width: 18px; height: 18px; top: 2px; left: 2px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px #0002; transition: transform .15s; }
body[data-dn-ui] input.dn57-switch:checked { background: #2563eb; border-color: #2563eb; }
body[data-dn-ui] input.dn57-switch:checked::after { transform: translateX(16px); }
.dn57-project-field { margin: 0; padding: 0; border: 0; min-width: 0; }
.dn57-project-field legend { padding: 0 0 10px; }
.dn57-project-field > p { margin-top: 10px; font-size: 11px; color: #858c97; line-height: 1.8; }
.dn57-projects { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.dn57-projects label { position: relative; cursor: pointer; min-width: 0; }
.dn57-projects label > span { display: flex; flex-direction: column; align-items: flex-start; gap: 5px; padding: 14px 10px; border: 1px solid #e1e5ec; border-radius: 10px; background: #fff; height: 100%; }
body[data-dn-ui] .dn57-projects input { position: absolute; right: 10px; top: 12px; margin: 0; accent-color: #2563eb; }
.dn57-projects input:checked + span { border-color: #2563eb; background: #f4f7ff; box-shadow: 0 0 0 1px #2563eb; }
.dn57-projects input:focus-visible + span { outline: 2px solid #2563eb; outline-offset: 3px; }
.dn57-projects i { color: #2563eb; padding-bottom: 5px; }
.dn57-projects strong { font-size: 12px; color: #263246; }
.dn57-projects small { color: #838b97; font-size: 10px; }
.dn57-note { display: flex; align-items: flex-start; gap: 9px; padding: 13px 14px; border-radius: 9px; background: #f7f9fc; border: 1px solid #e9edf3; font-size: 11px; color: #788394; line-height: 1.8; }
.dn57-note i { color: #5278bc; margin-top: 4px; flex-shrink: 0; }
body[data-dn-ui] .dn57-button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 42px; padding: 9px 14px; border: 1px solid #dfe3ea !important; border-radius: 9px !important; background: #fff !important; color: #475569 !important; font-size: 12px; font-weight: 600; white-space: normal; line-height: 1.6; text-align: center; text-decoration: none; box-shadow: none !important; }
body[data-dn-ui] .dn57-button:hover { background: #f8fafc !important; }
body[data-dn-ui] .dn57-button.dn57-primary { background: #2563eb !important; border-color: #2563eb !important; color: #fff !important; }
body[data-dn-ui] .dn57-button.dn57-primary:hover { background: #1d4ed8 !important; }
body[data-dn-ui] .dn57-button.dn57-danger { color: #c43a49 !important; border-color: #f2d5d9 !important; background: #fff8f9 !important; }
.dn57-icon-button { width: 38px; height: 38px; border: 1px solid #e5e7eb; background: #fff; border-radius: 9px; color: #718096; }
.dn57-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.dn57-check-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; font-size: 12px; color: #7c8492; }
.dn57-check-list i { color: #2e9d72; margin-right: 5px; }
.dn57-table-scroll { width: 100%; overflow-x: auto; }
.dn57-table { border-collapse: collapse; width: 100%; min-width: 650px; font-size: 12px; text-align: left; }
.dn57-table th { background: #f9fafc; color: #858d9b; font-size: 11px; font-weight: 600; padding: 12px 18px; }
.dn57-table td { padding: 15px 18px; border-top: 1px solid #edf0f4; }
.dn57-empty { padding: 28px 18px; text-align: center; color: #9ca3af; font-size: 12px; }
.dn57-details summary { display: flex; align-items: center; gap: 12px; padding: 18px 20px; cursor: pointer; list-style: none; }
.dn57-details summary::-webkit-details-marker { display: none; }
.dn57-details summary > span:nth-child(2) { flex: 1; }
.dn57-details summary strong { display: block; font-size: 13px; color: #374151; }
.dn57-details summary small { display: block; font-size: 11px; color: #8a919e; margin-top: 3px; }
.dn57-details summary > i { color: #a1a8b4; font-size: 10px; transition: transform .2s; }
.dn57-details[open] summary { border-bottom: 1px solid #eceef2; }
.dn57-details[open] summary > i { transform: rotate(180deg); }
.dn57-claims { max-height: 440px; overflow: auto; padding: 0 18px; }
.dn57-claim { display: grid; gap: 6px; padding: 15px 0; border-bottom: 1px solid #edf0f4; min-width: 0; }
.dn57-claim:last-child { border-bottom: 0; }
.dn57-claim-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.dn57-claim-name { font-size: 12px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dn57-claim-meta { font-size: 10px; color: #9ca3af; overflow-wrap: anywhere; }
.dn57-claim code { font-size: 11px; color: #4b6692; overflow-wrap: anywhere; }
.dn57-project-chip { font-size: 9px; padding: 3px 7px; border-radius: 5px; background: #eff4ff; color: #5277b4; flex-shrink: 0; }
.dn57-schedule-state { display: grid; gap: 8px; }
.dn57-schedule-state > p { color: #858c97; font-size: 11px; }
body[data-dn-ui] .dn57-services :is(#fk-schedule-status,#fk-telegram-status) { display: inline-block; width: fit-content; max-width: 100%; padding: 7px 10px; border-radius: 7px; font-size: 11px; background: #f3f6fb !important; color: #4e6c9d !important; border: 1px solid #e2e9f4 !important; }
.dn57-summary-card h3 { margin-top: 4px; font-size: 20px; color: #2563eb; }
.dn57-savebar { margin-top: 20px; border-top: 1px solid #e4e7ed; padding: 18px 0 2px; display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.dn57-savebar > span { font-size: 11px; color: #929aa7; }
.dn57-savebar > span i { margin-right: 4px; }
.library-project-upload { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 16px; margin-bottom: 16px; border: 1px solid #e5e9f0; border-radius: 10px; background: #f8faff; }
.library-project-upload label { font-size: 12px; font-weight: 600; }
.library-project-upload select { padding: 8px 12px; max-width: 100%; }
.library-project-upload p { width: 100%; margin: 0; color: #8791a3; font-size: 11px; }
.dn57-public-project { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border: 1px solid #dbe6fa; border-radius: 7px; background: #f0f5ff; color: #2563eb; font-size: 11px; font-weight: 600; margin: 8px 0; }
body.dn57-reset-public .macos-window { max-width: 600px; border-radius: 14px !important; }
body.dn57-reset-public .window-content { padding: 28px; }
body.dn57-reset-public .dn47-service-hero { text-align: left; margin: 22px 0; }
body.dn57-reset-public .dn47-service-hero .header-icon { width: 44px; height: 44px; border-radius: 11px; font-size: 19px; display: flex; margin-bottom: 16px; }
body.dn57-reset-public .dn47-service-hero h1 { font-size: 25px; margin: 5px 0 8px; line-height: 1.5; }
body.dn57-reset-public .dn47-service-hero p { font-size: 12px; line-height: 1.8; color: #858e9e; }
body.dn57-reset-public .notice { border: 1px solid #dfe7f5 !important; background: #f6f9ff !important; border-radius: 10px; padding: 14px; font-size: 11px; line-height: 1.9; }
body.dn57-reset-public .helper-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 16px 0 22px; }
body.dn57-reset-public .helper-card { border: 1px solid #e8ebf1; border-radius: 9px; padding: 13px; background: #fff !important; }
body.dn57-reset-public .helper-title { font-size: 11px; margin-bottom: 5px; }
body.dn57-reset-public .helper-text { font-size: 10px; line-height: 1.8; color: #939aaa; }
body.dn57-reset-public #key { min-height: 48px; font-size: 14px; }
body.dn57-reset-public #submitBtn { min-height: 46px; border-radius: 9px; margin-top: 6px; }
body.dn57-reset-public .window-footer { padding: 16px 28px; border-top: 1px solid #edf0f4; }
@media (max-width: 1050px) { .dn57-main-grid { grid-template-columns: 1fr; } .dn57-main-grid > aside { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
@media (max-width: 700px) {
    body.dn57-reset-public .window-content { padding: 20px; }
    body.dn57-reset-public .dn47-service-hero h1 { font-size: 23px; }
    .dn57-services { padding: 16px; gap: 16px; }
    .dn57-intro { align-items: flex-start; flex-direction: column; gap: 12px; }
    .dn57-services h2 { font-size: 20px; }
    .dn57-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
    .dn57-stat { padding: 13px 12px; gap: 9px; }
    .dn57-stat strong { font-size: 23px; }
    .dn57-stat-icon { width: 30px; height: 30px; font-size: 12px; border-radius: 8px; }
    .dn57-stat > div > span { font-size: 10px; }
    .dn57-columns, .dn57-main-grid > aside { grid-template-columns: 1fr; }
    .dn57-card-head, .dn57-details summary { padding: 16px; }
    .dn57-card-body { padding: 16px; gap: 16px; }
    .dn57-head-actions { align-items: flex-start; flex-wrap: wrap; }
    .dn57-head-actions > div:first-child { flex-basis: 100%; }
    .dn57-savebar { flex-direction: column; align-items: stretch; padding-bottom: 8px; }
    .dn57-savebar > span { text-align: center; }
    .library-project-upload { align-items: stretch; flex-direction: column; gap: 8px; }
}
@media (max-width: 400px) { .dn57-form-grid { grid-template-columns: 1fr; } .dn57-projects { gap: 7px; } .dn57-projects label > span { padding: 13px 7px 11px; } .dn57-projects strong { font-size: 11px; } .dn57-projects small { font-size: 9px; } }
@media (prefers-reduced-motion: reduce) { .dn57-services *, .dn57-services *::after { transition: none !important; } }
