body[data-theme="ops"] {
    --ops-header-title-size: 1.375rem;
    --ops-header-title-lh: 1.2;
    --ops-header-title-ls: -0.015em;
    --ops-header-sub-size: 0.8125rem;
    --ops-header-sub-lh: 1.45;
    --ops-header-sub-fw: 500;
    --ops-header-pill-font: 0.6875rem;
    --ops-header-pill-ls: 0.03em;
    background: #f3f4f6;
    color: #111827;
}

body[data-theme="ops"] .app {
    background: #f3f4f6;
}

body[data-theme="ops"] .header {
    background: #0b1531;
    border: none;
    border-radius: 0;
    margin-bottom: 0;
    margin-left: -10px;
    margin-right: -10px;
    padding: 22px 16px 16px;
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    row-gap: 14px;
}

body[data-theme="ops"] .header-row {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
}

body[data-theme="ops"] .header-row > div:first-child {
    width: auto;
    padding-left: 0;
}

body[data-theme="ops"] .header-main {
    flex: 1 1 auto;
    min-width: 0;
    padding-right: 12px;
}

body[data-theme="ops"] .header-row .title {
    color: #f8fafc;
    font-weight: 800;
    letter-spacing: var(--ops-header-title-ls);
    font-size: var(--ops-header-title-size);
    line-height: var(--ops-header-title-lh);
}

body[data-theme="ops"] .header-row .title .ops-title-tag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    margin-left: 8px;
    min-height: 1.375rem;
    height: 1.375rem;
    padding: 0 0.5625rem;
    border-radius: 999px;
    font-size: var(--ops-header-pill-font);
    font-weight: 600;
    letter-spacing: var(--ops-header-pill-ls);
    line-height: 1;
    color: #e2e8f0;
    vertical-align: middle;
    background: rgba(148, 163, 184, 0.18);
    border: 1px solid rgba(148, 163, 184, 0.32);
}

body[data-theme="ops"] .header-row .sub {
    color: #cbd5e1;
    font-size: var(--ops-header-sub-size);
    font-weight: var(--ops-header-sub-fw);
    line-height: var(--ops-header-sub-lh);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

body[data-theme="ops"] .header-row .sub::before {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 999px;
    background: #22c55e;
    flex-shrink: 0;
}

body[data-theme="ops"] .header-actions {
    margin-left: auto;
    gap: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: nowrap;
    width: auto;
    position: static;
}

body[data-theme="ops"] .ops-page-backbar.hidden {
    display: flex !important;
}

body[data-theme="ops"] .ops-page-backbar {
    margin: 0 0 10px;
}

body[data-theme="ops"] .ops-page-backbtn {
    border: none;
    background: transparent;
    color: #334155;
    font-size: 14px;
    line-height: 1.2;
    font-weight: 600;
    padding: 4px 0;
    border-radius: 0;
    min-height: auto;
}

body[data-theme="ops"] #tab-admin .ops-subpage-header {
    display: none;
}

body[data-theme="ops"] .app.ops-admin-active .header {
    display: none;
}

body[data-theme="ops"] .app.ops-admin-active {
    padding-top: 0;
}

body[data-theme="ops"] .app.ops-admin-active #tab-admin .ops-subpage-header {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #0b1531;
    color: #f8fafc;
    min-height: 132px;
    padding: calc(34px + env(safe-area-inset-top)) 20px 18px;
    margin: 0 -16px 0;
    border-bottom-left-radius: 12px;
    border-bottom-right-radius: 12px;
}

body[data-theme="ops"] .app.ops-admin-active #tab-admin .ops-subpage-backbtn {
    border: none;
    background: transparent;
    color: #f8fafc;
    font-size: 24px;
    line-height: 1;
    font-weight: 700;
    width: 34px;
    height: 34px;
    border-radius: 999px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

body[data-theme="ops"] .app.ops-admin-active #tab-admin .ops-subpage-title {
    font-size: 28px;
    font-weight: 700;
    letter-spacing: 0.2px;
    line-height: 1.1;
}

body[data-theme="ops"] .app.ops-admin-active #tab-admin #systemSettingsHome > .section-title,
body[data-theme="ops"] .app.ops-admin-active #tab-admin #systemSettingsHome > .small {
    display: none;
}

body[data-theme="ops"] .app.ops-admin-active #tab-admin #systemSettingsHome {
    margin-top: 20px;
}

@media (max-width: 768px) {
    body[data-theme="ops"] .app.ops-admin-active #tab-admin .ops-subpage-header {
        min-height: 124px;
        margin-left: -10px;
        margin-right: -10px;
        padding: calc(30px + env(safe-area-inset-top)) 18px 16px;
        border-bottom-left-radius: 10px;
        border-bottom-right-radius: 10px;
    }

    body[data-theme="ops"] .app.ops-admin-active #tab-admin .ops-subpage-backbtn {
        font-size: 22px;
        width: 32px;
        height: 32px;
    }

    body[data-theme="ops"] .app.ops-admin-active #tab-admin .ops-subpage-title {
        font-size: 26px;
    }
}

body[data-theme="ops"] #loginUserInfo.user-chip {
    display: none;
}

body[data-theme="ops"] #opsContactManagerBtn {
    display: none;
}

body[data-theme="ops"] #headerNoticeBell.header-notice-btn {
    width: 34px;
    height: 34px;
    border-radius: 999px;
    border: 1px solid #334155;
    background: rgba(15, 23, 42, 0.55);
    color: #e2e8f0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
    padding: 0;
}

body[data-theme="ops"] .header-notice-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

body[data-theme="ops"] .header-notice-svg {
    width: 18px;
    height: 18px;
}

body[data-theme="ops"] .header-notice-dot {
    width: 7px;
    height: 7px;
    border-radius: 999px;
    background: #ef4444;
    position: absolute;
    top: 3px;
    right: 3px;
}

body[data-theme="ops"] #headerSettingsAvatar.header-avatar-btn {
    width: 34px;
    height: 34px;
    border-radius: 999px;
    border: 1px solid #334155;
    background: rgba(15, 23, 42, 0.55);
    color: #f8fafc;
    font-weight: 700;
}

body[data-theme="ops"] .logout-btn {
    display: none;
}

body[data-theme="ops"] .tabs,
body[data-theme="ops"] .notice-entry-card,
body[data-theme="ops"] #todayScheduleList,
body[data-theme="ops"] #tab-chat > .compact-card {
    display: none !important;
}

body[data-theme="ops"] #tab-chat {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

body[data-theme="ops"] #tab-chat .card {
    border-radius: 16px;
    border: 1px solid #dde3ec;
    background: #fff;
    box-shadow: 0 6px 20px rgba(15, 23, 42, 0.05);
}

body[data-theme="ops"] #opsHomeMetrics {
    width: 100%;
    background: #0b1531;
    border: none;
    border-radius: 0;
    box-shadow: none;
    margin: 0;
    padding: 0;
}

body[data-theme="ops"] .ops-metrics-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
}

body[data-theme="ops"] .ops-metric-item {
    border-radius: 12px;
    border: 1px solid #30406a;
    background: #132347;
    padding: 8px 6px;
}

body[data-theme="ops"] .ops-metric-value {
    font-size: 24px;
    line-height: 1;
    font-weight: 800;
    color: #f8fafc;
}

body[data-theme="ops"] .ops-metric-item:nth-child(2) .ops-metric-value {
    color: #f59e0b;
}

body[data-theme="ops"] .ops-metric-item:nth-child(3) .ops-metric-value {
    color: #fb7185;
}

body[data-theme="ops"] .ops-metric-item:nth-child(4) .ops-metric-value {
    color: #60a5fa;
}

body[data-theme="ops"] .ops-metric-label {
    margin-top: 4px;
    font-size: 11px;
    color: #94a3b8;
}

body[data-theme="ops"] #opsNoticeCard {
    border-color: #f3ca92;
    background: #fff7eb;
    position: relative;
    padding-left: 46px;
    box-shadow: none;
    margin-top: 6px;
}

body[data-theme="ops"] #opsNoticeCard::before {
    content: "";
    position: absolute;
    left: 14px;
    top: 14px;
    width: 20px;
    height: 20px;
    border-radius: 999px;
    background: #fff;
    border: 1px solid #f59e0b;
    background-image:
        linear-gradient(#f97316, #f97316),
        radial-gradient(circle, #f97316 0 55%, transparent 56%);
    background-size: 2px 8px, 2px 2px;
    background-position: center 5px, center 14px;
    background-repeat: no-repeat;
}

body[data-theme="ops"] #opsNoticeCard .section-title {
    display: none;
}

body[data-theme="ops"] #opsNoticeCardText {
    color: #1f2937;
    line-height: 1.65;
    font-size: 14px;
}

body[data-theme="ops"] #opsTodayScheduleCard {
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 14px 16px 16px;
    border-color: #c8d7ef;
    background:
        radial-gradient(circle at 100% 0, rgba(59, 130, 246, 0.14), transparent 42%),
        linear-gradient(180deg, #ffffff 0%, #f5f9ff 100%);
}

body[data-theme="ops"] #opsTodayScheduleCard .ops-section-head {
    align-items: flex-start;
    gap: 10px;
}

body[data-theme="ops"] #opsTodayScheduleCard .section-title {
    margin: 0;
    font-size: 1.06rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.2;
    color: #0f3b8a;
}

body[data-theme="ops"] #opsTodayScheduleCard .ops-section-head .small {
    margin-top: 2px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.76rem;
    font-weight: 700;
    line-height: 1.25;
    color: #1d4ed8;
    background: linear-gradient(180deg, #eff6ff, #e0ecff);
    border: 1px solid #bfdbfe;
}

body[data-theme="ops"] #opsTodayScheduleInline {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 0 !important;
}

body[data-theme="ops"] #opsTodayScheduleInline:not(:has(.ops-schedule-row)) {
    padding: 12px 14px;
    border-radius: 12px;
    border: 1px dashed #93c5fd;
    background: linear-gradient(180deg, #f8fbff, #eff6ff);
    color: #1e3a8a;
    font-size: 0.84rem;
    line-height: 1.5;
}

body[data-theme="ops"] .ops-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

body[data-theme="ops"] #opsTodayScheduleCard .ops-section-head .section-title::before {
    content: "";
    width: 16px;
    height: 16px;
    margin-right: 6px;
    display: inline-block;
    vertical-align: -2px;
    border: 1.6px solid #64748b;
    border-radius: 4px;
    background-image:
        linear-gradient(#64748b, #64748b),
        linear-gradient(#64748b, #64748b),
        linear-gradient(#cbd5e1, #cbd5e1);
    background-repeat: no-repeat;
    background-size: 2px 4px, 2px 4px, 100% 1.6px;
    background-position: 4px 1.2px, 10px 1.2px, 0 5px;
}

body[data-theme="ops"] #opsTodayScheduleCard .ops-section-head .small::after {
    content: " ›";
    color: #94a3b8;
}

body[data-theme="ops"] #opsTodayScheduleInline .ops-schedule-table-head {
    grid-template-columns: 36px minmax(0, 1fr) max-content;
    padding: 0 12px 7px;
    margin-bottom: 0;
    color: #3b82f6;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

body[data-theme="ops"] #opsTodayScheduleInline .ops-schedule-row {
    display: grid;
    grid-template-columns: 36px minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    padding: 10px 12px;
    border-radius: 12px;
    border: 1px solid #d8e5f7;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

body[data-theme="ops"] #opsTodayScheduleInline .ops-schedule-badge {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: linear-gradient(180deg, #e0f2fe, #dbeafe);
    color: #1d4ed8;
    font-weight: 700;
    font-size: 0.88rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

body[data-theme="ops"] #opsTodayScheduleInline .ops-schedule-row.is-rest .ops-schedule-badge {
    background: #e5e7eb;
    color: #6b7280;
}

body[data-theme="ops"] #opsTodayScheduleInline .ops-schedule-main {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

body[data-theme="ops"] #opsTodayScheduleInline .ops-schedule-name {
    font-size: 0.95rem;
    font-weight: 700;
    color: #0f172a;
    line-height: 1.22;
}

body[data-theme="ops"] #opsTodayScheduleInline .ops-schedule-role {
    margin-top: 0;
    font-size: 0.8rem;
    line-height: 1.35;
    font-weight: 600;
    color: #475569;
}

body[data-theme="ops"] #opsTodayScheduleInline .ops-schedule-time {
    border: 1px solid #bfdbfe;
    border-radius: 999px;
    padding: 5px 10px;
    font-size: 0.78rem;
    font-weight: 700;
    line-height: 1.2;
    color: #1e3a8a;
    background: linear-gradient(180deg, #f0f7ff, #dbeafe);
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

@media (max-width: 768px) {
    body[data-theme="ops"] #opsTodayScheduleCard {
        padding: 13px 14px 14px;
        gap: 12px;
    }

    body[data-theme="ops"] #opsTodayScheduleInline .ops-schedule-row {
        grid-template-columns: 34px minmax(0, 1fr);
        gap: 10px;
        align-items: start;
    }

    body[data-theme="ops"] #opsTodayScheduleInline .ops-schedule-time {
        grid-column: 2;
        justify-self: start;
        margin-top: 2px;
    }
}

body[data-theme="ops"] #opsWorkbench .ops-workbench-tabs {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 10px;
}

body[data-theme="ops"] #opsWorkbench .ops-workbench-tabs .small-btn {
    min-height: 40px;
    border-radius: 10px;
    border-color: #d4dbe7;
    background: #f8fafc;
    color: #334155;
    font-weight: 700;
}

body[data-theme="ops"] #opsWorkbench .ops-workbench-tabs .small-btn.is-active {
    background: #0b1736;
    border-color: #0b1736;
    color: #fff;
}

body[data-theme="ops"] .ops-entry-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

body[data-theme="ops"] .ops-entry-card {
    border: 1px solid #dde3ec;
    border-radius: 12px;
    background: #fff;
    padding: 12px;
    text-align: left;
    color: #111827;
    position: relative;
}

body[data-theme="ops"] .ops-entry-card.has-icon {
    padding-left: 56px;
}

body[data-theme="ops"] .ops-entry-icon {
    position: absolute;
    left: 20px;
    top: 16px;
    width: 28px;
    height: 28px;
    border-radius: 9px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #eef2ff;
    color: #475569;
}

body[data-theme="ops"] .ops-entry-icon svg {
    width: 18px;
    height: 18px;
    stroke: currentColor;
    fill: none;
    stroke-width: 1.9;
    stroke-linecap: round;
    stroke-linejoin: round;
}

body[data-theme="ops"] .ops-entry-card.ops-entry-due .ops-entry-icon {
    background: #fff7ed;
    color: #ea580c;
}

body[data-theme="ops"] .ops-entry-card.ops-entry-purchase .ops-entry-icon {
    background: #eff6ff;
    color: #2563eb;
}

body[data-theme="ops"] .ops-entry-title {
    font-weight: 700;
    font-size: 16px;
}

body[data-theme="ops"] .ops-entry-sub {
    margin-top: 4px;
    font-size: 12px;
    color: #6b7280;
    line-height: 1.4;
}

body[data-theme="ops"] #opsQuickEntryCard .section-title {
    font-size: 24px;
}

body[data-theme="ops"] #opsQuickEntryCard input,
body[data-theme="ops"] #opsQuickEntryCard textarea,
body[data-theme="ops"] #opsQuickEntryCard select {
    border-radius: 12px;
    border-color: #d4dbe7;
    background: #f8fafc;
}

body[data-theme="ops"] #opsQuickEntryCard .actions {
    display: block;
}

body[data-theme="ops"] #opsQuickEntryCard .actions .secondary {
    display: none;
}

body[data-theme="ops"] #opsQuickEntryCard .primary {
    width: 100%;
    min-height: 44px;
    font-size: 17px;
    font-weight: 700;
    background: #0b1736;
    border-color: #0b1736;
    color: #fff;
}

body[data-theme="ops"] .ops-weekly-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

body[data-theme="ops"] .ops-weekly-item {
    border-radius: 12px;
    padding: 12px;
}

body[data-theme="ops"] .ops-weekly-green {
    background: #eef8f0;
}

body[data-theme="ops"] .ops-weekly-blue {
    background: #eef3ff;
}

body[data-theme="ops"] .ops-weekly-value {
    margin-top: 6px;
    font-size: 38px;
    line-height: 1;
    font-weight: 800;
    color: #111827;
}

body[data-theme="ops"] #recentLogs {
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    overflow: hidden;
    background: #fff;
}

body[data-theme="ops"] #recentLogs .record-row {
    padding: 12px 14px;
    border-bottom: 1px solid #eef2f7;
}

body[data-theme="ops"] #recentLogs .record-row:last-child {
    border-bottom: none;
}

body[data-theme="ops"] #recentLogs .record-name {
    font-weight: 700;
}

body[data-theme="ops"] #recentLogs .record-meta-inline,
body[data-theme="ops"] #recentLogs .record-source-inline {
    color: #6b7280;
}

body[data-theme="ops"] #opsHomeMetrics { order: 10; }
body[data-theme="ops"] #opsNoticeCard { order: 20; }
body[data-theme="ops"] #opsTodayScheduleCard { order: 30; }
body[data-theme="ops"] #opsWorkbench { order: 40; }
body[data-theme="ops"] #opsQuickEntryCard { order: 50; }
body[data-theme="ops"] #confirmArea { order: 60; }
body[data-theme="ops"] #resultArea { order: 70; }
body[data-theme="ops"] #opsWeeklyStats { order: 80; }
body[data-theme="ops"] #tab-chat > .card:last-child { order: 90; }

body[data-theme="ops"] #opsWorkbench {
    margin-bottom: 10px;
    border-radius: 20px;
    padding: 12px 14px 10px;
    overflow: hidden;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.05);
}

body[data-theme="ops"] #opsWorkbenchContent {
    margin: 10px -14px -10px;
    padding: 10px 14px 12px;
    background: #f8fafc;
    border-top: 1px solid #e7ecf3;
    border-radius: 0;
    box-shadow: none;
}

body[data-theme="ops"] #opsWorkbenchContent #opsDueListCard,
body[data-theme="ops"] #opsWorkbenchContent #opsFollowListCard {
    margin: 0 !important;
    padding: 12px 0 0;
    border: none;
    border-radius: 0;
    box-shadow: none;
    background: transparent;
}

body[data-theme="ops"] #opsWorkbenchContent #opsFollowListCard {
    border-top: 1px solid #e6ebf2;
    margin-top: 10px !important;
    padding-top: 14px;
}

body[data-theme="ops"] #opsWorkbenchContent #opsDueListCard .section-title,
body[data-theme="ops"] #opsWorkbenchContent #opsFollowListCard .section-title {
    font-size: 15px;
    font-weight: 700;
    margin-bottom: 8px;
}

@media (max-width: 768px) {
    body[data-theme="ops"] .app {
        padding: 10px 10px calc(16px + env(safe-area-inset-bottom));
        gap: 10px;
    }

    body[data-theme="ops"] .header {
        margin-left: -10px;
        margin-right: -10px;
        border-radius: 0;
        padding: 22px 16px 14px;
    }

    body[data-theme="ops"] .header-main {
        padding-right: 10px;
    }

    body[data-theme="ops"] .header-row .title {
        font-size: 20px;
    }

    body[data-theme="ops"] .header-row .sub {
        font-size: 13px;
    }

    body[data-theme="ops"] .header-actions {
        width: auto;
        margin-left: auto;
        justify-content: flex-end;
        flex-wrap: nowrap;
        gap: 10px;
    }

    body[data-theme="ops"] .header-row {
        flex-direction: row;
        align-items: flex-start;
    }

    body[data-theme="ops"] .header-row > div:first-child {
        width: auto;
        padding-left: 0;
    }

    body[data-theme="ops"] .ops-metrics-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 6px;
    }

    body[data-theme="ops"] .ops-metric-item {
        padding: 8px 6px;
    }

    body[data-theme="ops"] .ops-metric-value {
        font-size: 22px;
    }

    body[data-theme="ops"] .ops-entry-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
